Re: Javascript detection , working version

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2007-01-02 at 21:55 +0100, Satyam wrote:
> ----- Original Message ----- 
> From: "Robert Cummings" <robert@xxxxxxxxxxxxx>
> To: "Jürgen Wind" <jwind@xxxxxx>
> Cc: <php-general@xxxxxxxxxxxxx>
> Sent: Tuesday, January 02, 2007 8:57 PM
> Subject: Re:  Javascript detection , working version
> 
> 
> > On Tue, 2007-01-02 at 11:32 -0800, Jürgen Wind wrote:
> >> Robert Cummings wrote:
> >> >
> >> > Out of curiosity, can you guarantee the Javascript redirect will always
> >> > occur before the meta redirect when Javascript is enabled? Otherwise 
> >> > you
> >> > have a race condition.
> >> >
> >> > Cheers,
> >> > Rob.
> >> >
> >> i have no idea, it is just a quick&dirty  hack, i'm no js expert ;)
> >> the js part is rather fast, maybe a little delay or window.write is
> >> neccessary after the redirect?
> >
> > No, you always want the javascript to run first. The question is whether
> > a meta redirect could ever occur before the javascript redirect. If it
> > can then occasionally you may get "javascript not detected" since the
> > meta redirect would occur when in fact javascript is enabled.
> >
> > Cheers,
> > Rob.
> > -- 
> 
> What I usually do is to make the entry page the one that would be used 
> without JavaScript and branch only if JavaScript is present.

Yeah, that was what I did :)

Cheers,
Rob.
-- 
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux