Hi,
I have a form which has an input field called "year", and once the submit button is clicked, the following code will run.
<?php
$userinput = @$_POST["year"];
$path = "index.php?mC=$userinput.php";
Header("Location: $path");
?>
The above code will display a page inside a div on my main page and this works fine. What i would like to do is to see if i can alter the above code, so that if the page is not found, i will take the user to a not found page withing my index.php page.
I know that it has to be done something along the if ... else statement, but not sure which keywords to use.
Thank you for any help.