Home > Backend Development > PHP Tutorial > 如何把4字节数字转为16进制

如何把4字节数字转为16进制

WBOY
Release: 2016-06-13 12:04:18
Original
3664 people have browsed it

怎么把4字节数字转为16进制?
我只知道dechex函数,但转出来是 

<br />echo dechex(1407401322869);<br />
Copy after login

afa7e975

计算器选四字节出来的结果147afa82c60 才是我要的结果

请问怎么用PHP实现?
------解决方案--------------------
你那是什么计算器?
应该是 147AFA7E975
echo base_convert(1407401322869, 10, 16); //147afa7e975<br />
Copy after login

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