Posts Tagged ‘mysql’

Why is the PHP file content printed instead of runned?

I have Apache/MySQL/PHP on Windows XP.

I want my PHP files to behave in my computer like in web host.

I open a PHP file with FF and its content is printed!

Can xampp make my computer vulnerable?

I downloaded xampp a few months ago, mainly to learn php/mysql. I know that it is not secure and should not be used for live projects, but can anybody access my computer externally when I am running it? I recently found a trojan on my computer and as a result an account I have has been hacked into, so I’m a little paranoid about security now. Any tips on how to completely secure xampp would be greatly appreciated.

php security question about $_Session['id']?

You have at least 3 registered users in the MySQL database.
ID. Name Email
1. John john@john_com
2. Mark mark@mark_edu
3. Peter peter38@peter3_edu

To visit member’s area on the web-site, they have to enter login and password.

Is it secure that their $_session['id'] is the number they received during the registration in the MySQL database (1,2,3,… etc) ? Or, $_session['id'] should be a unique, but a long string like a crypted password?
I have no idea, if $_session['id'] can be stolen and hackers can use $_session['id'] (without password) to crack the account?

So, $_session['id']=’3′ – is that OK? Or, $_session['id'] should be unique, but at least 32+ bits?

P.S. ID of every user is not the password and the password is encrypted properly.

One guy told me there is no sense to worry about $_session['id'], because even if a bad guy knows your $_session['id'], he can’t use it to access your account (because the web-brower has some kind of smart connection with a server and you can’t duplicate it from another computer). I’m not sure if he’s right.

Any ideas with explanations are highly appreciated. Please experts only. Thank you.

How to make login system in php mysql?

How to make login system in php mysql?

Continue Parse PHP after DB Connection Error?

Hi there, I’m working on a piece of my website that reads info from the database, and displays it. It works great. So now I want to see what happens when a database connection error occurs, so I stop the mysql service. What happens, is a message is printed to the screen saying it can’t connect (auto mysql message), but my entire php script stops parsing.

How can I get it to keep going, just not display the database results?

Thanks.

TigerDirect