router router - 4 years ago 116
HTML Question

php no error but blank output page

this is my php code i am trying to get out put on same page but now out put is beng shown and there is no error is being shown also. can you help me enter image description here

<form action="try.php" method="POST">
<input type="text" name="txtname">
<input type="text" name="txtage">
<input type="submit" value="send" name="submit">

if(isset($_POST['txtname']) && isset($_POST['txtage'])){
echo $text;
echo $age;

Answer Source

It should be $_POST and not $_post. $_POST is one of PHP's superglobals and must be in all caps. $_post will be treated as a local variable. (ref)

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download