zeusthegreat Posted February 11, 2011 Report Share Posted February 11, 2011 in lesson 7 functions part 2 begining php videos i followed the code !DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4loose.dtd"> <html> <head> <meta http-equiv="Content-Type" Content="text/html; charset=iso-8859-1"> <title></Title> </head> <body> <h4>Functions - The Users Perspective</h4> <?php $words = " many words in this sentence...."; $result = str_word_count($words); echo $result . "<br><br>"; $did_send = mail('stefan@killerphp.com','killerphp.com Test Email', "The body message."); echo "Email Sent: " . $did_send; ?> and viewed in browser and got back Functions - The Users Perspective 5 Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\email.php on line 25 Email Sent: i wondered if this is a problem or not because i have not stipulated a mailserver and have not verified my smtp can somebody clarify please thankyou Quote Link to comment Share on other sites More sharing options...
Wickham Posted February 11, 2011 Report Share Posted February 11, 2011 Was the page online? You won't be able to send an email from a PHP page on your computer without a special email server. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.