PHPMailer

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
nick2price
Forum Newbie
Posts: 18
Joined: Fri Nov 13, 2009 5:49 pm

PHPMailer

Post by nick2price »

Hi. I am using php mailer to send emails. I have this bit of code

Code: Select all

	$mail->SMTPAuth   = true;                  // enable SMTP authentication
	$mail->Port       = 25;                    // set the SMTP server port
	$mail->Host       = "mail.tester.com"; // SMTP server
	$mail->Username   = "info@tester.com";     // SMTP server username
	$mail->Password   = "";            // SMTP server password
I cant see how placing my smtp password in this php file, and then placing it on my server, will be very secure. Whats the normal procedure to adding passwords to php files, and how can i protect them?

cheers
shridhar.govindaiah
Forum Newbie
Posts: 3
Joined: Wed Jun 30, 2010 8:13 am

Re: PHPMailer

Post by shridhar.govindaiah »

Hi nick2price,

U cant encrypt and place ur smtp server password here. Instead of that u can create a dummy account and use that username and password for sending a mail.
Account should be valid in ur SMTP server.


Cheers,
Shridhar Govindaiah,
Samarthainfo Solutions Pvt Ltd.
Post Reply