Re: [PHP] PHP & JavaScript

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

 



>Have somebody any idea how I could do something like that?

<snip javascript and PHP>

You're somewhat out of luck, as the chain of events in your typical HTTP
transaction looks something like this...

	---->[time]--------------------------------->
	client request received from browser
	 |
	 +-> PHP code executed on server
	      |
	      +-> text output to webserver (including javascript source)
	           |
	           +-> [drawing of cloud representing internet]
	                |
	                +-> text input to web browser on client side
	                     |
	                     +-> javascript executed by client
	---->[time]--------------------------------->

...The only way to have the javascript affect the PHP, is to make a
subsequent request /back/ to the server after the javascript has started
executing. You can, for example, package the screen size into a GET
variable appended to an image request.

---------------------------------------------------------------------
michal migurski- contact info and pgp key:
sf/ca            http://mike.teczno.com/contact.html

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


[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux