A PHP extension wrapping libcouchbase
C PHP Perl C++ Shell
Pull request Compare This branch is 3 commits ahead, 49 commits behind couchbase:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
example
fastlz
management
package
tests
tools
.gitignore
CONTRIBUTING.md
CREDITS
LICENSE
README.md
TESTING.pod
apidecl.c
apidecl.h
arithmetic.c
ccache.c
compress.c
config.m4
config.w32
convert.c
couchbase.c
couchbase.php
create.c
designdoc.c
error.c
exceptions.c
exceptions.h
flush.c
get.c
ht.c
ht.h
internal.h
misc.c
observe.c
options.c
package.xml
php_couchbase.h
remove.c
resget.h
resmgr.c
simple_observe.c
simple_observe.h
stat.c
store.c
timeout.c
touch.c
unlock.c
version.c
viewopts.c
views.c
views.h

README.md

ext/couchbase

A PHP extension wrapping libcouchbase.

Dependencies

libcouchbase igbinary (optional)

Installation

End users should install the module by executing:

$ pecl install couchbase

Developers who want to build the latest bits from the source repository may execute the following steps

$ phpize
$ ./configure
$ make
$ make test

Running make test assumes that you have a Couchbase server listening on port 127.0.0.1:8091

If you are using a webserver installation of PHP, you might need to restart your webserver.

If you have igbinary installed, make test will most likely fail with an error message reporing a missing symbol. Don't worry; it has an explanation. During make test php generates another php.ini file for us which don't include the igbinary module. To work around this all you need to do is to edit the Makefile and add the following as the first parameter parameter to run-tests.php:

-d extension=/absolute/path/to/igbinary.so

First Step

Create a new script test.php:

<?php
$cb = new Couchbase("127.0.0.1:8091", "Administrator",
                    "password", "default");
$cb->set("a", 1);
$a = $cb->get("a");
echo $a;
?>

Compatibility

PHP 5.3 or later.

Windows support is coming in the next release.

License

Apache License 2.0

Credits

See CREDITS file. Thanks all!

Copyright

(c) 2011, 2012, 2013 Couchbase

Contributions

If you'd like to contribute to the project, please look in CONTRIBUTING.md.