Module:Md5

From Thorium Mod Wiki
Jump to navigation Jump to search

This module computes the MD5 hash value of an input string. It is mainly intended to be used from within templates.

Usage

{{ #invoke:Md5 | md5 | <input string> }}

Examples

Code Result
{{#invoke:Md5|md5|The quick brown fox jumps over the lazy dog}} 9e107d9d372bb6826bd81d3542a419d6



local p = {
}
-- for template.
p.md5 = function(frame)
		return mw.hash.hashValue('md5', frame.args[1])
end

p.MD5 = p.md5

return p