[Lancaster] Help needed with email from web pages
Matt Fletcher
matt at matt-fletcher.co.uk
Thu Jun 28 15:09:53 BST 2007
You can always try the PHP manual: http://uk2.php.net/mail
Whenever I've had problems setting up mail on local web servers, it's
always needed me to install sendmail/change the path to it/use smtp
delivery. A lot of these settings will be in your php.ini file.
Matt Fletcher
Email: info at matt-fletcher.co.uk
Web: http://www.matt-fletcher.co.uk/
Phone: 01524 426559
Mobile: 07792 148897
Ken Hough wrote:
> Hi Guys!
>
> Can you help me? I'm building a website and need to provide for sending
> email messages from within the site.
>
> I been using PHP and for test/dev purposes run my own local webserver
> (apache with mod_php). I know that the web server and the PHP bit work
> OK, because the website uses PHP successfully for a number of other tasks.
>
> Using the very simple code:
>
> <?php
> // The message
> $message = "Line 1\nLine 2\nLine 3";
>
> // In case any of our lines are larger than 70 characters, we should use
> wordwrap()
> $message = wordwrap($message, 70);
>
> // Send
> $x = mail('kenhough at uklinux.net', 'My Subject', $message);
>
> echo $message.'<br>';
> if($x == TRUE) echo "TRUE".'<br>';
> if($x == FALSE) echo "FALSE".'<br>';
> ?>
>
> appears to send a message --- at least judging by the LED activity on
> my ADSL /router, but no messages appear in my mail box and 'TRUE' is
> echoed to the screen.
>
> What am I missing?
>
> Can annyone recomend a good Internet link on the subject?
>
>
> Ken Hough
>
> _______________________________________________
> Lancaster mailing list
> Lancaster at mailman.lug.org.uk
> https://mailman.lug.org.uk/mailman/listinfo/lancaster
More information about the Lancaster
mailing list