SitePoint Sponsor

User Tag List

Page 1 of 3 123 LastLast
Results 1 to 25 of 70
  1. #1
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    How do i send message to email?

    Hi,
    I need some help on how to do this,i have a registration form and i want that if the user will submit it will send message to his/her email,
    can you help me please how to do this...
    Thank you in advance and i am hoping for your positive response.

  2. #2

  3. #3
    Foozle Reducer ServerStorm's Avatar
    Join Date
    Feb 2005
    Location
    Burlington, Canada
    Posts
    2,699
    Mentioned
    89 Post(s)
    Tagged
    6 Thread(s)
    To further ralph.m's recommendations, If you do know a little php then http://swiftmailer.org/ is a fantastic mail library for PHP. It allows you to do a number of advanced things, yet it has great documentation and can also be set to the most basic of needs.

    Steve
    ictus==""

  4. #4
    SitePoint Enthusiast
    Join Date
    Jun 2007
    Location
    Frankfurt/Germany
    Posts
    66
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I was using http://sourceforge.net/projects/phpmailer/ in a couple of projects. Easy to use, very robust.

  5. #5
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Hi, sorry for my late reply.thank you so much for this link,i will write again to you.thank you so much for helping me.

  6. #6
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ServerStorm View Post
    To further ralph.m's recommendations, If you do know a little php then http://swiftmailer.org/ is a fantastic mail library for PHP. It allows you to do a number of advanced things, yet it has great documentation and can also be set to the most basic of needs.

    Steve

    Hi,thank you for helping me.i hope can learn more something in this forum..thank you again.

  7. #7
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    @mainlink..thank you so much for this..

  8. #8

  9. #9
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ServerStorm View Post
    To further ralph.m's recommendations, If you do know a little php then http://swiftmailer.org/ is a fantastic mail library for PHP. It allows you to do a number of advanced things, yet it has great documentation and can also be set to the most basic of needs.

    Steve

    Hi, i get back on this thread because i want to ask just a simple sending email into the user email address,.because i am not yet familiar on those suggestion,..my point is can i use a mail function in php to send email,

    I am just working on the local in my desktop is it possible to perform this sending mail in local?...i have registration just as simple form,i want that when i am going to click the register it will send to the email address...like yahoo or gmail..

    secondly do i have something to do or to have configuration in my php.ini inorder to perform this sending mail...actually i have never tried this,but i want to learn on this.I hope you can help me and provide some steps...i just want to use simple sending email and after this i will try those suggestion in this thread.

  10. #10
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ServerStorm View Post
    To further ralph.m's recommendations, If you do know a little php then http://swiftmailer.org/ is a fantastic mail library for PHP. It allows you to do a number of advanced things, yet it has great documentation and can also be set to the most basic of needs.

    Steve
    Hi, i downloaded now the swiftmailer and also i extracted it, but i don't know how to use this.

  11. #11
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,330
    Mentioned
    463 Post(s)
    Tagged
    8 Thread(s)
    Quote Originally Posted by jemz View Post
    do i have something to do or to have configuration in my php.ini inorder to perform this sending mail...
    Doing this from your local computer often does require something extra like this. It's easier just to test this online. Have you checked out the swiftmailer documentation?

  12. #12
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ralph.m View Post
    Doing this from your local computer often does require something extra like this. It's easier just to test this online. Have you checked out the swiftmailer documentation?
    yes i downloaded it and i extract the file, and then i read the documentation but i am confuse,i dont know how to install and used it...please help me on this.how can i used the swift mailer.

  13. #13
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ServerStorm View Post
    To further ralph.m's recommendations, If you do know a little php then http://swiftmailer.org/ is a fantastic mail library for PHP. It allows you to do a number of advanced things, yet it has great documentation and can also be set to the most basic of needs.

    Steve

    this is my code this is the first time i use swift mailer but i find dificulty to use.

    Code:
    <?php
    
    
    
    require_once './lib/swift_required.php';
    
    function swiftmailer_configurator() {
        // configure Swift Mailer
    
        Swift_DependencyContainer::getInstance();
        Swift_Preferences::getInstance();
    }
    
    Swift::init('swiftmailer_configurator');
    Swift::init('swiftmailer_configurator');
    
    
    
    // Create the Transport
    $transport = Swift_SmtpTransport::newInstance('localhost', 25)
      ->setUsername('root')
      ->setPassword('')
      ;
      
    // Sendmail
    $transport = Swift_SendmailTransport::newInstance('/usr/sbin/sendmail -bs');  
      
     //MAIL 
    $transport = Swift_MailTransport::newInstance();
    
    
    // Create the Mailer using your created Transport
    $mailer = Swift_Mailer::newInstance($transport);
    
    
    
    
    
    // Create the message
    $message = Swift_Message::newInstance()
    
    
    
    
    
      // Give the message a subject
      ->setSubject('This is my subject')
    
      // Set the From address with an associative array
      ->setFrom(array('mygmail@gmail.com' => 'John Doe'))
    
      // Set the To addresses with an associative array
      ->setTo(array('tomyemail@yahoo.com' => 'A name'))
    
      // Give it a body
      ->setBody('Here is the message itself testing....!')
    
    
      ;
    
    
    
    // Send the message
    $result = $mailer->send($message);
    
     if($result==1)
       echo 'successfully send';
    else {
    	 echo 'failed to send';
    }

  14. #14
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    It's easier just to test this online
    I have internet connection...but i don't have domain like my www.mywebsite.com...I just want to test in local computer using swift mailer and can sent email to yahoo.com or gmail.com etc...I am really confuse how can i achieve this sending mail.i hope you can help me ralph.

    Thank you in advance.

  15. #15
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ralph.m View Post
    Doing this from your local computer often does require something extra like this. It's easier just to test this online. Have you checked out the swiftmailer documentation?
    Can i use swiftmailer only for development purposes i am just in local computer but i have internet connection i just want to try to send email using swiftmailer,I hope you understand what i mean.

  16. #16
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,330
    Mentioned
    463 Post(s)
    Tagged
    8 Thread(s)
    PHP and server stuff is not my area, and I haven't used swiftmailer. You might need to earch for info on setting up your local server, such as this:

    http://email.about.com/od/emailprogr...nding_Mail.htm

  17. #17
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ralph.m View Post
    PHP and server stuff is not my area, and I haven't used swiftmailer. You might need to earch for info on setting up your local server, such as this:

    http://email.about.com/od/emailprogr...nding_Mail.htm
    Hi ralph, thank you for the reply...okay i will try this link maybe this will help me..

  18. #18
    Foozle Reducer ServerStorm's Avatar
    Join Date
    Feb 2005
    Location
    Burlington, Canada
    Posts
    2,699
    Mentioned
    89 Post(s)
    Tagged
    6 Thread(s)
    Hi jemz,

    The best way to test this is to set up a local WAMP or LAMP stack on your development computer. In swiftmailer use whatever smtp you use for your regular email and route via localhost or 127.1.0.0. The php can be ran and tweaked under the LAMP stack.

    I recommend keeping it the simplest configuration at first - until you get the mail flowing - and then add complexity as you go.

    I don't have time right now to go through your configuration, so hopefully this helps get you pointed in the right direction.

    Regards,
    Steve
    ictus==""

  19. #19
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ServerStorm View Post
    Hi jemz,

    The best way to test this is to set up a local WAMP or LAMP stack on your development computer. In swiftmailer use whatever smtp you use for your regular email and route via localhost or 127.1.0.0. The php can be ran and tweaked under the LAMP stack.

    I recommend keeping it the simplest configuration at first - until you get the mail flowing - and then add complexity as you go.

    I don't have time right now to go through your configuration, so hopefully this helps get you pointed in the right direction.

    Regards,
    Steve

    Hi ServerStorm,

    Thank you for the reply...but how do i know the smtp that i use.

    use whatever smtp you use for your regular email

    I am using wamp here.

  20. #20
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ServerStorm View Post
    Hi jemz,

    The best way to test this is to set up a local WAMP or LAMP stack on your development computer. In swiftmailer use whatever smtp you use for your regular email and route via localhost or 127.1.0.0. The php can be ran and tweaked under the LAMP stack.

    I recommend keeping it the simplest configuration at first - until you get the mail flowing - and then add complexity as you go.

    I don't have time right now to go through your configuration, so hopefully this helps get you pointed in the right direction.

    Regards,
    Steve

    Hi ServerStorm,

    Thank you for the reply...but how do i know the smtp that i use.

    use whatever smtp you use for your regular email

    I am using wamp here.

  21. #21
    Foozle Reducer ServerStorm's Avatar
    Join Date
    Feb 2005
    Location
    Burlington, Canada
    Posts
    2,699
    Mentioned
    89 Post(s)
    Tagged
    6 Thread(s)
    Quote Originally Posted by jemz View Post
    Hi ServerStorm,

    Thank you for the reply...but how do i know the smtp that i use.




    I am using wamp here.
    You will use the smtp that your ISP provides. Normally they publish this on their web-site; however you can also call them to determine what is their non-authenticated SMTP.

    Regards,
    Steve
    ictus==""

  22. #22
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ServerStorm View Post
    You will use the smtp that your ISP provides. Normally they publish this on their web-site; however you can also call them to determine what is their non-authenticated SMTP.

    Regards,
    Steve
    Hi, THank you for the reply..i am just using wi-fi from my neighbor and i paid to them every month.

  23. #23
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,330
    Mentioned
    463 Post(s)
    Tagged
    8 Thread(s)
    You'll need to ask your neighbors what ISP they use, if you don't know.

  24. #24
    SitePoint Wizard
    Join Date
    May 2012
    Posts
    1,159
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by ralph.m View Post
    You'll need to ask your neighbors what ISP they use, if you don't know.
    Thank you ralph for the reply....Okay but what if they don't?....is there any other ways to get the ISP

  25. #25
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,330
    Mentioned
    463 Post(s)
    Tagged
    8 Thread(s)
    Quote Originally Posted by jemz View Post
    but what if they don't?
    Check to see if they lack a pulse. That's the only reason I can think why they wouldn't know.

    They can just check their bill to see whom they pay.

    Then go to the website of their ISP and find out what their smtp is.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •