Anybody help me ?
I need a php script that will run automatically every day on Morning 09:00 O'clock. But my script not working. My script.
<?php
date_default_timezone_set('Asia/Calcutta');
$now = date("h:i");
$base = '09:00';
$to = 'test@mydomain.com';
$subject = 'My Subject';
$message = 'Hello';
$headers = 'From: test@mydomain.com' . "\r\n" .
'Reply-To: test@mydomain.com' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
if ($now == $base) {
mail($to, $subject, $message, $headers);
}
?>
Thanks in advance!