File: README.md

package info (click to toggle)
php-msgpack 0.5.5-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 1,396 kB
  • ctags: 361
  • sloc: ansic: 3,937; xml: 333; php: 18; makefile: 2
file content (35 lines) | stat: -rw-r--r-- 710 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# Msgpack for PHP

This extension provide API for communicating with MessagePack serialization. 

MessagePack is a binary-based efficient object serialization library.
It enables to exchange structured objects between many languages like JSON.
But unlike JSON, it is very fast and small.

## Requirement
- PHP 5.0 +

## Install

### Install from PECL
Msgpack is an PECL extension, thus you can simply install it by:
````
pecl install msgpack
````
### Compile Msgpack from source
````
$/path/to/phpize
$./configure 
$make && make install
````

### Example
```php
<?php
$data = array(0=>1,1=>2,2=>3);
$msg = msgpack_pack($data);
$data = msgpack_unpack($msg);
?>
```
# Resources
 * [msgpack](http://msgpack.org/)