Skip to content
PHP extension for the xxhash library
Branch: develop
Clone or download
Pull request Compare This branch is 1 commit ahead of stuartherbert:develop.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
README.md
config.m4
config.w32
php_xxhash.c
php_xxhash.h
xxhash.c
xxhash.h

README.md

php-xxhash

PHP extension to add support for the xxhash - r42 extremely fast hashing algorithm. xxhash is designed to be fast enough to use in real-time streaming applications.

How To Install

   phpize
   ./configure --enable-xxhash
   make
   sudo make install

How To Use

This extension adds three new PHP functions:

    // 32 bit version (all values are positive)
    int xxhash32(string $data);
    
    // 64 bit version (can return negative values since PHP doesn't support unsigned long values)
    long xxhash64(string $data);
    
    // 64 bit version (all values are positive but returned as strings)
    string xxhash64Unsigned(string $data);

They will checksum the string, and return the checksum.

License

BSD 2-clause license.

You can’t perform that action at this time.