2

I created a file for sending the email from my site in php via SMTP. To do this I followed a guide where he said that you had to write as text in the sending file (MailSMTP.php) both the email address and the password of the account from which you want to start the emails.

My question is: How can I hide the password in my php file in such a way that if a user tracks my php file (MailSMTP.php) can not read the text of my password in frontend?

The code that I would like to obscure from the php file is this:

$password = "xxxxxxx";

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.