kellyalan Posted March 20, 2014 Share Posted March 20, 2014 Just want to get clarification on what this does and why you'd want it displayed in email output: .bin2hex(mhash(MHASH_MD5, time())) Thanks Quote Link to comment Share on other sites More sharing options...
Jacques1 Posted March 21, 2014 Share Posted March 21, 2014 (edited) Hi, I guess even the author of the code doesn't know what it's for. Where on earth does this come from? The code is an extremely cumbersome way of writing md5(time()) Why would one hash the current Unix time? I have absolutely no idea. Maybe they wanted a fixed length. Or maybe it's a botched security feature. Edited March 21, 2014 by Jacques1 Quote Link to comment Share on other sites More sharing options...
Solution Ansego Posted March 21, 2014 Solution Share Posted March 21, 2014 (edited) Hi, I also agree with @Jacques1; Has the explanation in more detail on the php manual: bin2hex Reference: http://www.php.net/manual/en/function.bin2hex.php Mhash Reference: http://www.php.net/manual/en/ref.mhash.php md5 Reference: http://au2.php.net/md5 Edited March 21, 2014 by Ansego Quote Link to comment Share on other sites More sharing options...
kellyalan Posted March 21, 2014 Author Share Posted March 21, 2014 Thanks for the replies and links -- I inherited this code and wasn't quite sure why this was used Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.