How do I secure a hardcoded login/password in PHP?

karabaja2

New Member
I'm writing a simple PHP script to access the Foursquare API. The PHP will always access the same Foursquare account. For the time being, I have this login information hardcoded in my script. What is the best way to secure this information?If I follow the advice from this thread, I should just place the login information in a config file outside the website's root directory:http://stackoverflow.com/questions/97984/how-to-secure-database-passwords-in-phpIs this the best advice? Or is there a better way to secure the login information?
 
Back
Top