警告:mail():无法在/ home / ipx12489 / public_html /中执行邮件传递程序'/ usr / sbin / sendmail -t -i'

I got the above warning when i am trying to send email with ajax from a php file. i am trying code:

$to = "suman5571@gmail.com";
$subject = "This is subject";

$message = "<b>This is HTML message.</b>";
$message .= "<h1>This is headline.</h1>";

$header = "From:suman5571@gmail.com 
";
$header = "Cc:dhillon0jags@gmail.com 
";
$header .= "MIME-Version: 1.0
";
$header .= "Content-type: text/html
";

$retval = mail ($to,$subject,$message,$header);

if( $retval == true ) {
    echo '1';
} else {
    echo '0';
}

You should check your sendmail_path settings in php. Also check if the program exists and is installed.