漢字加密解密,為了解決傳輸時,漢字符會丟失的問題
<code><span>$urlstr</span> = urlencode(<span>"我是codekissyoung"</span>); <span>echo</span> urldecode(<span>$urlstr</span>);</code>
不可逆加密md5散列值,sha1 散列值
<code><span>echo</span> md5(<span>"hehexiix23"</span>); <span>echo</span> crypt(<span>$some_string</span>,<span>'keyvalue'</span>); <span>$str</span> = <span>'apple'</span>; <span>if</span> (sha1(<span>$str</span>) === <span>'d0be2dc421be4fcd0172e5afceea3970e2f3d940'</span>) { <span>echo</span><span>"Would you like a green or red apple?"</span>; }</code>
可逆加密
<code>base64_encode(<span>$string</span>); base64_decode(<span>$string</span>); convert_uudecode(<span>$str</span>); convert_uuencode(<span>$str</span>);</code>
rrreee
可逆加密rrreee用之於民!歡迎轉載,轉載請開頭附上本文鏈接,不定期更新文章!
🎜 🎜 以上就介紹了php 加密解密,包含了面向的內容,希望對PHP教學有興趣的朋友有幫助。 🎜 🎜 🎜