Re: Distinguishing between multiple browser windows for the same php session

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

 



Gustav Wiberg wrote:
<?php echo $_SELF;?>  ?

Please don't top-post [1].

This will not work. $_SELF isn't even a defined variable, unless you defined it yourself.

PHP works on the server, *before* anything is sent on the client, so it has no way to know client-side things like what browser window you are in.

You could place the value in a hidden form field with JS and then post back to the server, but something tells me you may be approaching the problem in the wrong way. Without more details I can't suggest alternatives, though.

[1] http://en.wikipedia.org/wiki/Top-posting

--
Jasper Bryant-Greene
Freelance web developer
http://jasper.bryant-greene.name/

If you find my advice useful, please consider donating to a poor
student! You can choose whatever amount you think my advice was
worth to you. http://tinyurl.com/7oa5s

--
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