Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

php question regarding email

Options
  • 07-02-2008 7:02pm
    #1
    Closed Accounts Posts: 51 ✭✭


    im trying to get an email to be sent from my email address to all users that register with my site, however i keep getting an smtp.port and host error each time i go to run the page.
    im not sure wat this is?


Comments

  • Registered Users Posts: 31 markkilpatrick


    have you got your smtp server set in your php.ini file?


  • Closed Accounts Posts: 51 ✭✭poissys


    have you got your smtp server set in your php.ini file?

    i haven't got that done no, how do i go about doing it, i know nothing about it, excuse my ignorance


  • Closed Accounts Posts: 1,200 ✭✭✭louie


    did you look into the php mail http://ie2.php.net/mail
    [php]
    mail($to, $subject, $msg, $headers);
    [/php]
    function.
    Grab the email from DB, and using while....loop send the email one by one.


  • Moderators, Politics Moderators Posts: 38,996 Mod ✭✭✭✭Seth Brundle


    louie wrote: »
    did you look into the php mail http://ie2.php.net/mail
    [php]
    mail($to, $subject, $msg, $headers);
    [/php]function.
    Grab the email from DB, and using while....loop send the email one by one.
    Obviously remembering to tackle email injection before of course!


  • Registered Users Posts: 31 markkilpatrick


    poissys wrote: »
    i haven't got that done no, how do i go about doing it, i know nothing about it, excuse my ignorance

    Do you have hosting somewhere or are you running your webserver on your pc?

    if yes:

    In your php.ini file you will find:
    SMTP = localhost
    smtp_port = 25
    This will need to be changed to your isp's smtp.

    Otherwise if you have hosting with somebody you shouldnt need to do this.

    If you post an example of your code it will be eaiser to help.


  • Advertisement
Advertisement