I have the following code in two files separately
file one.php
It's not recognized because you don't create it. Variables don't magically appear in PHP1. You need to get that value from the $_POST superglobal:
<HTML>
<BODY>
<?PHP
$age = $_POST['age'];
print ("The age is: $age");
?>
</BODY>
</HTML>
1 Anymore. They used to when register_globals existed. But that has been obsolete since long before you started coding.
Your trying to access the value of age from a page( dos.php) but you posting it to (two.php) and your missing $_POST['age'].
one.php
<HTML>
<BODY>
<FORM ACTION="two.php" METHOD="POST">
Age: <INPUT TYPE="text" NAME="age">
<INPUT TYPE="submit" VALUE="OK">
</FORM>
</BODY>
</HTML>
two.php
<HTML>
<BODY>
<?PHP
$age = $_POST['age'];
print ("The age is: $age");
?>
</BODY>
</HTML>