Trying to add some minimal validation when updating a record, but I am getting an include error.
Here is the validation code:
if (strlen($_POST['fname']) > 30) {
$message = "Character cannot be more than...";
include 'edit.php?id=' . $_POST['id'];
exit();
}
Here is my error:
Warning: include(edit.php?id=97) [function.include]: failed to open stream: No such file or directory in /Applications/MAMP/htdocs/Homework/Advanced/LittleSprout/update.php on line 13
Warning: include() [function.include]: Failed opening 'edit.php?id=97' for inclusion (include_path='.:/Applications/MAMP/bin/php/php5.3.6/lib/php') in /Applications/MAMP/htdocs/Homework/Advanced/LittleSprout/update.php on line 13
I have no idea what I am doing wrong. It says it can't find the file or directory, but it's there, and within the same folder where edit.php is located. Any suggestions? Thanks in advance.