Hi guys .
I have the following code, how can i redirect the user to message.php
after submitting the form or page.
PHP Code:
<?php
//ob_start();
  
include('../common/adm_inc_commons.php');
    
$sql="select * from m_user where nruser = $nruser";
    
$result mysql_query($sql) or err_handler();
     
$row mysql_fetch_object($result);
     
$nmname=$row->nmname;
     
$nmpass=$row->nmpassword;
     
$nmlogin=$row->nmlogin;
     
$nric=$row->nric;
     
$nmemail=$row->nmemail;
//******************************************************************************
  
$sql1="select * from m_parent_child where nruser=$nruser";
  
$result_listmysql_query($sql1) or err_handler();
  
$row mysql_fetch_array($result);
  
$childarray=$row->nruser_child;
  
//*********************************************************************************************
  
$sql="select * from m_user where nruser='$childarray' and cdcat='2'";
             
$result_childmysql_query($sql) or mysql_error();
             
$row_child mysql_fetch_array($result_child);
             
$name=$row_child->nmname;
             
$login=$row_child->nmlogin;
             
$pass=$row_child->nmpassword;
//********************************************************************************************
if (isset($_POST['btnsave_x'])) {
  
$email =htmlentities($_POST['nmemail']);
  
$msg =($_POST['message']);
  
$subject =htmlentities($_POST['subject']);
     
$headers 'From: Straight-As Team <support@straight-a.com>' "\r\n" .
    
'Cc: xxxxx@yahoo.com' "\r\n" .
    
'X-Mailer: PHP/' phpversion() ."\r\n".
    
'MIME-Version: 1.0' "\r\n" .
    
'Content-type: text/html; charset=iso-8859-1' "\r\n";
    
$message "
Dear valued subscriber,<br>
Welcome to Straight-As Program.<br>
Thank you for showing interest in Straight-As program.<br><br>

    "
.$msg."
<br>
Kindly keep the above information for future references.<br>

For further information please contact:<br>
support@straight-a.com.<br>

Best regards,<br>
Straight-As Team.
"
;

 
$mail=mail($email,$subject,$message,$headers);
 }
 
// If (!$mail'){header("Location:message.php");}//else {header("Location:message.php");}
// header("Location:message.php");
 
?>

<html>
<head>
<title>Straight-As:Customer</title>
</head>
<?php  include('../common/adm_inc_top.php'); ?>

<body>
<?PHP include('adm_cus_send_pass_form.php')?>
</body>

</html>