...the conditions of an if statement are fulfilled?
I have some code to add data to a database if certain conditions are met, after the data is added I want the page to redirect to another page? How can I do this?
Use if-else condition. You can use header() of PHP .
if(/* Your conditions */){
// redirect if fulfilled
header("Location:nxtpage.php");
}else{
//some another operation you want
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With