PHP cannot call a javascript function. but PHP can examine the incoming variables and then output Javascript to the browser to do the appropriate work.
for example, calling $text.php?this=5 pops up an alert saying "this=5" test.php <? print "<script>\n". "alert('this='+". $this .");\n". "</script>" ?> Marcel Besancon wrote: > Hi, > > i know that one is server-side and the other is client-side. But what i > meant ist the following. I have a script with a form. By submitting this > form and checking out some values php should call a javascript-function > (such as an alert). You see the php-script shall call the > javascript-function by "refreshing" the whole page. > > Bye, > > Marcel > > -- > registered Fli4l-User #00000388 > "Scott Furt" <[EMAIL PROTECTED]> schrieb im Newsbeitrag > [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > >>Short answer: no. >> >>Long answer: have the PHP script output javascript code >>to the browser. >> >>PHP = server-side >>Javascript = client-side >> >>Marcel Besancon wrote: >> >>>Hi everybody, >>> >>> is there someone who can tell me how to call a javascript-function >>> > by a > >>>php-script. >>> >>>Thanks for each answer >>> >>>Marcel >>> >>>-- >>>registered Fli4l-User #00000388 >>> >>> >>> >>> >>> >> > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php