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
amir
Forum Contributor
Posts: 287 Joined: Sat Oct 07, 2006 4:28 pm
Post
by amir » Fri Feb 16, 2007 8:36 am
Hello,
We normally use connection string in this way
Code: Select all
<?php
$link = mysql_connect('localhost', 'mysql_user', 'mysql_password');
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);
?>
I want to know that is it secure on Shared Hosting. If not please advise how can we make it secure?
TIA!
superdezign
DevNet Master
Posts: 4135 Joined: Sat Jan 20, 2007 11:06 pm
Post
by superdezign » Fri Feb 16, 2007 8:39 am
You mean, can people with access to your FTP see your username and password? Yes.
You could write your own encryption/decryption function and "hide" it from the other users if you really want to hide your password from them.