I want to gather information from the user and display it on another page.
In the file commit.php I have 2 fields
Product name:
Description:
<TR><TD ALIGN="right" VALIGN="middle" width="40%"> Product name:
</TD>
<TD ALIGN="right" valign="middle"><input name="name" size="27" type="text"></TD>
</TR>
<TR><TD ALIGN="right" VALIGN="middle">Description: </TD>
<TD ALIGN="right"> <textarea name="desc" rows="5"></textarea>
</TD>
</TR>
And in the file add_new.php I want to display whatever text user wrote in those two fields Product name and description.
<?php
if (isset ($_POST['name']) || isset ($_POST['desc']))
{
echo'<form action="add_new.php" method="POST" name="submit">
<TR><TD ALIGN="right" VALIGN="middle" width="40%"> Product name:
</TD>
<TD ALIGN="right" valign="middle"><input name="name" size="27" type="text" value="'.$_POST['name'].'"></TD>
</TR>
<TR><TD ALIGN="right" VALIGN="middle">Description: </TD>
<TD ALIGN="right"><textarea name="desc" rows="5" value="'.$_POST['desc'].'"></textarea>
</TD>
</TR>
</form>';
}
?>
Unfortunatelly nothing is displayed althought there are no errors.