php MD5 encryption code:

WBOY
Release: 2016-08-08 09:29:56
Original
1246 people have browsed it

<code><span><span><<span>body</span><span>style</span>=<span>"color:green;font-size:28px;background:black;font-family:Verdana, sans-serif;"</span>></span><span><span><?php</span> error_reporting(<span>0</span>);<span>?></span></span><span><<span>form</span><span>name</span>=<span>"c"</span><span>action</span>=<span>"<?php echo $_SERVER['PHP_SELF'];?>"</span><span>method</span>=<span>"get"</span>></span>
Input your text:
<span><<span>input</span><span>type</span>=<span>"text"</span><span>name</span>=<span>"c"</span> /></span><span><<span>button</span><span>type</span>=<span>"submit"</span><span>value</span>=<span>"Submit"</span><span>style</span>=<span>"color:green;font-size:28px;background:black;"</span>></span>Creat!<span></<span>button</span>></span><span></<span>form</span>></span><span></<span>body</span>></span><span><span><?php</span><span>//hash encode:</span><span>if</span>(<span>$c</span>=<span>$_GET</span>[<span>'c'</span>])<span>echo</span><span>'Roger!Your MD5 code is:<br>'</span>.md5(<span>$c</span>).<span>'(32bit)<br>'</span>.substr(md5(<span>$c</span>),<span>8</span>,<span>16</span>).<span>'(16bit)'</span>;<span>//截取8到24就是16位的hash,便于储存</span><span>?></span></span></code>
Copy after login

The above introduces the php MD5 encryption code:, including the relevant content. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!