如何压缩一段文本后存入mysql
程序员文章站
2023-12-27 16:57:39
...
先加载模块extension=php_zlib.dll
PHP代码:--------------------------------------------------------------------------------
$x="hello world";
$x=gzcompress($x) ; //压缩
echo $x ;
echo "
";
echo gzuncompress($x); //解压
?>
--------------------------------------------------------------------------------
PHP代码:--------------------------------------------------------------------------------
$x="hello world";
$x=gzcompress($x) ; //压缩
echo $x ;
echo "
";
echo gzuncompress($x); //解压
?>
--------------------------------------------------------------------------------