The following codes are HTML and php code. I want if submit button is pressed than execute practice.php file(make test.txt file). But if I pressed the button php doesn't make file. Anyone know about this??\[code\]<HTML> <HEAD> </HEAD> <BODY onLoad="tid=setInterval('refresh()',1000);"> <div id="outputDiv"></div> <form method=post action="practice.php"> <script language="JavaScript"> function refresh() { var HTML = ""; HTML += "<input type=submit value=http://stackoverflow.com/questions/13787281/makefile>"; document.getElementById("outputDiv").innerHTML = HTML; } </script> </form> </BODY></HTML> <html> <head><meta http-equiv="Content-Type" content="text/html" charset="utf-8"> </head> <body> <? $fp = fopen("test.txt", "w") or die("cannot open file"); $data = "http://stackoverflow.com/questions/13787281/!!!!!!!!!!!!!!!!!!!"; fwrite($fp, $data); fclose($fp); echo "!!!!!!!!!!!!!!!"; ?> </body></html>\[/code\]