send Gmail from php form
email, gmail, php
Solution
Take a look to: http://www.web-development-blog.com/archives/send-e-mail-messages-via-smtp-with-phpmailer-and-gmail/
Problem
I have a project to setup an anonymous feedback form to our website. I wanted to have a go at it with php the general idea is that I would have a password field (give out to our employees) a field for the feed back and a button to Ive seen this code snippet ``` <?php $to = "recipient@example.com"; $subject = "Hi!"; $body = "Hi,\n\nHow are you?"; if (mail($to, $subject, $body)) { echo("<p>Message successfully sent!</p>"); } else { echo("<p>Message delivery failed...</p>"); } ?> ``` But im pretty sure with my limited understanding email systems that i can't just send out email (unless i have an open server somewhere which i do not) so i would need to log on to and email server (in my case gmails server) so how would i do this? update: the code above does work but it doesn't come from a corporate account we currently use Google biz apps and that's why I would like to log on to a Google server to send this out.