How can I make a simple file that will allow a user to input a name and message, and then output this information on a separate page?
<? foreach ($_POST as $pkey=>$pval) { print $pkey . ': ' . $pval; } ?>PHP] Something like that.
What the heck?
Does anyone know?
yea.... easy:
html: <html> <form method="post" action="somephpscript.php"> <input type="text" name="myname"> <input type="submit">
php:
print "$myname";
... etc...
Yeah but it doesn't stay there. I need this output to ADD.
Like if I type a 1, it'll output a 1 to a page. Next time I come to the input area and enter a 2, it;l ADD this 2 to that page and I can read 2, 1, etc
It is not a hard question...?
Are you saving your data to a flat file or other database? That is the only way that your information will stay. You need to create a php file that will log your information so when come back it will simply be read from the file. Each time you enter information in the form the php file will add another line to your file, then you can read off the data you just entered into you file on the second php that you create to view the files contents... is this what you were looking for?
If you don't understand the file functions in php (which I can understand... there is a million of them), check out the php site here: http://www.php.net/manual/en/function.file.php
Hope that helps.