Home >Backend Development >PHP Tutorial >php中怎的将1变成一个字节的Integer类型啊

php中怎的将1变成一个字节的Integer类型啊

PHP中文网
PHP中文网Original
2017-03-31 16:06:181025browse

  php中怎样将1变成一个字节的Integer类型啊?
pack函数怎么用啊?

------解决方案--------------------
prck('c', 1) 单字节有符号整数
prck('C', 1) 单字节无符号整数

与 chr(1) 等价

 以上就是php中怎的将1变成一个字节的Integer类型啊的内容,更多相关内容请关注PHP中文网(www.php.cn)!

Statement:
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