Little md5 question

Ask about general coding issues or problems here.

Moderators: egami, macek, gesf

Post Reply
Oleg Butuzov
Last Samuray
Last Samuray
Posts: 824
Joined: Sun Jun 02, 2002 3:09 am

Thu Jan 02, 2003 4:30 am

Kriz wrote:I have a login-page and used this code before

Code: Select all

if ($user == "admin" && $password == "password"){header("Location: admin.php");}

But now i want to make it more secure. I thought using md5, and my password in md5 is fc6c719000535d3cb73f2f658ef47d92. But how is the php-code gonna look like then?

Code: Select all

if ($user == "admin" && md5($password) == md5("password")){header("Location: admin.php");}

Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 2 guests