Logial Correction, and statement of the obvious
<?php
/*
logical construct depends on your data,,,
validate data entries,
if valid
insert to mysql,
disable submit so data will not be aded to table twice,
or redirect to another page
else
echo feedback to user to explain what is right/wrong with the submitted data before the form is resubmitted
*/ ?>
<form action='<?php iecho $_SERVER['PHP_Self']; ?>'>
<input type='text' name='field1' value='<?php if(isset($field1)){echo $field1; } ?>'>
<input type='text' name='field2' value='<?php if(isset($field2)){echo $field2; } ?>'>
<input type='text' name='field3' value='<?php if(isset($field3)){echo $field3; } ?>'>
<input type='text' name='field4' value='<?php if(isset($field4)){echo $field4; } ?>'>
<input type='submit' onclick="return confirm('Are all fields complete?')">
Last edited by almostbob; Jan 8th, 2009 at 11:50 pm.
Failure is not an option It's included free
If at first you dont succeed, join the club
Please mark solved problems, solved