Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Old password check, update password
Old 04-16-2008, 09:07 PM Old password check, update password
Gilligan's Avatar
Website Designer

Posts: 1,670
Name: Stefan
Location: London, UK
Trades: 0
How do I check if the field of 'old password' matches that of the database??

if it does...execute the sql query.
__________________

Please login or register to view this content. Registration is FREE
Gilligan is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 04-16-2008, 11:45 PM Re: Old password check, update password
Webmaster Talker

Posts: 560
Trades: 0
Just check to see if the text they entered (md5 hashed) = the password field in the database, which should be hashed already.

Matt
__________________

Please login or register to view this content. Registration is FREE
170 Designs is offline
Reply With Quote
View Public Profile
 
Old 04-17-2008, 09:01 AM Re: Old password check, update password
Gilligan's Avatar
Website Designer

Posts: 1,670
Name: Stefan
Location: London, UK
Trades: 0
How would I code that, I'm not great with SQL commands
__________________

Please login or register to view this content. Registration is FREE
Gilligan is offline
Reply With Quote
View Public Profile
 
Old 04-17-2008, 12:15 PM Re: Old password check, update password
Webmaster Talker

Posts: 560
Trades: 0
When first inserting the password into the database, run this first:

http://us2.php.net/md5

Then when the user types in the old password, run the same thing and then compare this to the password stored in the database. Should be basically:

if (oldpassword = passwordinDB)
run sql query

You'll just need to do the exact syntax and also grab the password from the DB before you do that and store it in something temporary

Matt
__________________

Please login or register to view this content. Registration is FREE
170 Designs is offline
Reply With Quote
View Public Profile
 
Old 04-17-2008, 12:41 PM Re: Old password check, update password
Gilligan's Avatar
Website Designer

Posts: 1,670
Name: Stefan
Location: London, UK
Trades: 0
I md5 it anyway

Just found what I could do,

if (oldpass == password cookie)
__________________

Please login or register to view this content. Registration is FREE
Gilligan is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Old password check, update password
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.21738 seconds with 12 queries