Didn't work, addadd.php has a error in the line 10
Fixed code:
every string that should be printed on the screen inside of <?php and ?> must be done with print or echo...
Also you may want to remove http://localhost/ from your a tags and header function..
Fixed code:
PHP Code:
<?php
$salary=$_GET["wage"]*$_GET["hours"]*$_GET["days"];
$rname=$_GET["fname"];
$file=fopen("test.txt","a");
fwrite($file,$rname);
fwrite($file,": ");
fwrite($file,$salary);
fwrite($file,"<br>");
fclose($file);
echo <<<HTML
<script type="text/javascript">
<!--
window.location = "http://localhost/home.php"
//-->
</script>
HTML;
?>
every string that should be printed on the screen inside of <?php and ?> must be done with print or echo...
Also you may want to remove http://localhost/ from your a tags and header function..