How to use PHP function pack to process data_PHP tutorial

WBOY
Release: 2016-07-15 13:33:43
Original
894 people have browsed it

We are learning

PHP function pack definition:

Compress data into a bit string.

Syntax:

string pack(string format, mixed [args]...);

Return value:

String

PHP function pack type:

Data processing

PHP function Pack content description

This function is used to compress and pack data into a string. This function has exactly the same functionality and usage as the Perl function of the same name. The parameter format is the compressed format

<ol class="dp-xml"><li class="alt"><span><span class="tag"><?</span><span class="tag-name">php</span><span> </span></span></li><li><span>echo pack("C3",80,72,80);  </span></li><li class="alt"><span class="tag">?></span><span> </span></span></li></ol>
Copy after login

Output:

PHP

The above is the definition and usage of PHP function pack.


www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/446035.htmlTechArticleWe are learning the definition of PHP function pack: Compress data into a bit string. Syntax: string pack(string format, mixed [args]...); Return value: String PHP function pack type: Data processing...
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
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!