here is my code, and it's not submitting to a text file
index.html
Code:
<!DOCTYPE html>
<html>
<body>
<center><form action="post.php" method="get">
<input type="text" name="name"><br>
<input type="submit" value="Submit">
</form></center>
</body>
</html>
post.php
Code:
<?php $file = 'myfile.txt';file_put_contents($file, print_r($_POST, true), FILE_APPEND);?>
<meta http-equiv="refresh" content="0; url=http://google.com" />
I am not seeing what the problem is, Is it something in my html file, what is $_POST and what variable is the html file storing the input from the textbox in? I have already setup the permissions on the files in the apache server and this still isn't working.