Cannot access $_POST [SOLVED]
Posted: Sun Jun 07, 2009 7:10 pm
I'm trying to do something exceedingly simple and failing completely at it. I want to submit a form using the post method. Then, on the page the form data is posted to, I want to print *something* (anything at all will do at this point). Something like this:
HTML Code
PHP Code
This is a trivial example and not at all what I want to do in my code, however, it's what I've reduced it to in an attempt to get things working. At the moment, whenever I submit the form, it just refreshes the page and nothing happens. Can anyone please offer some insight as to why this isn't working? It's absolutely infuriating me. Also, the action is left blank intentionally - I want to post the information to the current page.
HTML Code
Code: Select all
<form action="" method="post">
<input type="text" id="blah"/>
<input type="Submit" value="Save"/>
</form>Code: Select all
if ($_POST)
echo 'Information posted';