Jump to content

Archived

This topic is now archived and is closed to further replies.

richardsussex

Dreamweaver cms and md5 security???

Recommended Posts

Hi there, I have just finished a basic CMS for my website, using Dreamweaver!! I now want to make the page where i modify my content to have password security so only i can edit my content!!

 

I have incorperated a membership system into another site I have built!!

I dont really need a membership system on the new site!!

I just want one admin login!!

Im thinking md5() is the way to go??

Any tips or ideas would be great???

Share this post


Link to post
Share on other sites

Heres something you can try

Put this on the page of admin editing:

 

<?php

$password = "hamsters";

$md5pass = MD5($password);

if ($checkauth != NULL) {

echo "<form action=\'admin.php\' method=post>

<b>Password:</b><br>

<input type=\'text\' name=\'checkauth\' length=\'10\'><br>

<input type=\'submit\' value=\'Log in...\'></form>";

}

else {

$checkauth2 = MD5(\'$checkauth\');

if ($md5pass == $checkauth2) {

echo "

CODE FOR EDITING HERE CODE FOR EDITING HERE

CODE FOR EDITING HERE CODE FOR EDITING HERE

CODE FOR EDITING HERE CODE FOR EDITING HERE

CODE FOR EDITING HERE CODE FOR EDITING HERE

CODE FOR EDITING HERE CODE FOR EDITING HERE

CODE FOR EDITING HERE CODE FOR EDITING HERE";

}

else {

echo "Invalid Password!";

}

}

?>

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.