html - posting to .php downloads instead of showing up -


ok i'm new php.here i'm trying do. here index.html

<html>    <body>       <form action="welcome.php" method="post">           name: <input type="text" name="fname">           age: <input type="text" name="age">           <input type="submit">        </form>    </body> </html> 

i'm posting welcome.php

<html>    <body>       welcome <?php echo $_post["fname"]; ?>!<br>       <?php echo $_post["age"]; ?> years old.    </body> </html> 

but instead of showing page, downloads welcome.php

make sure server has php installed. if have php installed, try restarting server.


Comments

Popular posts from this blog

curl - PHP fsockopen help required -

HTTP/1.0 407 Proxy Authentication Required PHP -

c# - Resource not found error -