Re: [PHP] Using a HTML button

2002-01-11 Thread sundogcurt
JAVASCRIPT VERSION mytitle function multiply(x){ var myresult = 2 * x; document.write(myresult); } PHP VERSION mytitle if($mybutton){ $myresult = 2 * $mybutton; pr

Re: [PHP] Using a HTML button

2002-01-11 Thread Richard S. Crawford
PHP is entirely server-based. So when you load this page into your browser, all of the PHP is being parsed BEFORE it ever loads into the browser. So the function will be executed even before the page loads. Do it in JavaScript if you want it to be done in the browser. What you have written

Re: [PHP] Using a HTML button

2002-01-11 Thread Nick Wilson
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 * On 11-01-02 at 22:48 * Morten Nielsen said > Hi, > > I am rather new to PHP so I hope somebody can help me. > > I have a normal button (HTML code). Then I have made a function > > function multiply($X) > { > return 2*$X; > } > > The b