I am designing online shopping (college project) site where after placing the order the system will send an email to user's email id. I have seen some tutorials but I am unable to figure out what is the problem.
I have edited php.ini of XAMPP as follows:
[mail function]
; XAMPP: Comment out this if you want to work with an SMTP Server like Mercury
SMTP = smtp.gmail.com
smtp_port = 25
; For Win32 only.
; http://php.net/sendmail-from
sendmail_from = skanungo2007@gmail.com
Now my code for sending the email:
<?php
$to='skanungo2007@ymail.com';
$message='hello';
mail($to, 'My Subject', $message);
?>
Any solution for the problem??