if(!$pcode){
echo "Postcode is a required field. Please enter it below.<br />";
}
echo "<br>";
include 'rform.php';
exit(); // Here is the problem!
}
The required field check works and the form is included but the rest of my page does not load, it exits from displaying anything. is there a way that i can exit from the next stage of the script but still show the rest of my html?
The reason the rest of your page isnt being displayed is because of exit();. It stops the code from running from that point on. To fix this, try ending the PHP area and then using the rest of the HTML as just HTML, and dont echo it.