<?php
//需要加密的字符串
$str = "this is string"
//通过sha1进行加密
$res = sha1($str)
//通过指定第二个参数加密
$res = sha1($str,true)
?>
$imgtxt = file_get_content('test.jpg')file_put_content('test.txt', base64_encode($imgtxt))
<?php
//需要加密的字符串
$str = "this is string"
//通过sha1进行加密
$res = sha1($str)
//通过指定第二个参数加密
$res = sha1($str,true)
?>
$imgtxt = file_get_content('test.jpg')file_put_content('test.txt', base64_encode($imgtxt))