sxrxnnrr wrote:i cant get to work a simple html form with php...
i can't see any of the information introduced in the html form...it just shows an empty page
sxrxnnrr wrote:these were the only changes i made to the httpd.conf file
ScriptAlias /php/ "c:/php/"
AddType application/x-httpd-php .php
AddType application/x-httpd-php .php3
AddType application/x-httpd-php .php4
AddType application/x-httpd-php .htm
AddType application/x-httpd-php .html
AddType application/x-httpd-php .phtml
Action application/x-httpd-php "/php/php.exe"
when i execute phpinfo(); it works fine but i can't get to pass a variable from a html form to use it in any other place.
mynmonic wrote:I have checked this forum and I found that many people here have the same problem as mine, that I cannot retrieve the variable content to php script from html form. This is a simple sample I copy from my beginner's book, and it's just don't work in my LAMP:
<form action="thisfile.php" method="GET">
<p>Give your name: <input type="text" name="yourname">
<br><input type="submit" name="Submit">
very simple isn't it? but the $yourname inside the php tags can just never get the value of the yourname that I type in the text box, it's empty.
I noticed that this seems work in php3 but not php4 right? So how is the correct way to do this? even my php4 begineer book is teaching the wrong thing
parxal wrote:In php4 you can't use $yourname, you have to use : $_POST['yourname'];
because global vars are off
Users browsing this forum: Google [Bot] and 2 guests