0
I’m making a simple php script that receives the login data from an html form, only apparently html is not calling the php script.
snippet of html code:
<form action="index.php" method="post">
Login:<br>
<input type="text" name="userr"><br>
<br>
Senha:<br>
<input type="password" name="senha"><br>
<br>
<input type="submit" value="OK"><br>
</form>
Excerpt from php code:
ini_set("display_erros", 1);
echo "passou 1";
if($_Server['REQUEST_METHOD'] == 'POST'){
echo "passou 2";
...
What’s wrong with that code? ps: neither of these two Echos are printing something. The php and html code are in the same file "index.php".
What is your http server?
– fbiazi
Apache, httpd..
– Mr. Satan
Hello John already tried to use the # there in the action how to deal with the same file can be used # does not need to put the name of the file itself. example: <form action="#" method="post">
– Ivan Antunes