I'm trying to set up a mail server using gmail. So far after modifying code in C:\wamp\bin\apache\apache2.2.22\bin\php.ini. It hangs the page and just loads the browser. I have read that it has to be used with PHPmailer but I don't know how to. Please help me how to set up mail server.

[mail function]
; For Win32 only.
; http://php.net/smtp
SMTP = smtp.gmail.com
; http://php.net/smtp-port
smtp_port = 465

; For Win32 only.
; http://php.net/sendmail-from
sendmail_from = myemail@gmail.com
;you@yourdomain

Member Avatar for LastMitch

@pcvrx660

Here is the link to PHPMailer:

http://phpmailer.worxware.com/index.php

Click -> Product -> PHPMailer -> Support

This will show you how to install PHPMailer.

I finally got it.

Thank you for registering! You may now log in and access the site's content.
SMTP -> FROM SERVER:220 mx.google.com ESMTP i10sm739893igb.12
SMTP -> FROM SERVER: 250-mx.google.com at your service, [64.108.196.214] 250-SIZE 35882577 250-8BITMIME 250-AUTH LOGIN PLAIN XOAUTH XOAUTH2 250 ENHANCEDSTATUSCODES
SMTP -> FROM SERVER:250 2.1.0 OK i10sm739893igb.12
SMTP -> FROM SERVER:250 2.1.5 OK i10sm739893igb.12
SMTP -> FROM SERVER:354 Go ahead i10sm739893igb.12
SMTP -> FROM SERVER:250 2.0.0 OK 1351916597 i10sm739893igb.12
Message sent!

Member Avatar for LastMitch

@pcvrx660

It's great to hear that you solve it! So you did follow the instructions!

Can you click Mark Question Solve on the bottom left corner so the thread is close and solve so noone can add stuff to it. Thanks.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.