MLPHP is a set of PHP classes that provide connectivity to MarkLogic via PHP. It makes it easy to store XML, JSON, binary, and text documents, manage document metadata, and create sophisticated search queries on a web server running PHP (version 5.4 or greater).

MLPHP comes with API documentation and code examples to get you going. It communicates with MarkLogic using the server’s REST API. It requires MarkLogic 6 or later.

The API includes:

  • Documents and metadata storage and management
  • String-based, “google-style”, one-box search
  • Search-option configuration

After installing and configuring MLPHP, you can load documents into MarkLogic with just a couple lines of PHP code:

$document = new MLPHPDocument($client);

Searching is just as easy:

$search = new MLPHP\Search($client);
$results = $search->retrieve('cat');

Installation instructions are here.

Visit the Repository

Learn More

MLPHP Documentation

Review over the documentation for MLPHP that contains many code examples to get you going.

REST Application Guide

Read the extensive guide that reviews over REST Application development in MarkLogic.

Installation Instructions

Find the installation instructions that describe how you can add MLPHP to your project.

This website uses cookies.

By continuing to use this website you are giving consent to cookies being used in accordance with the MarkLogic Privacy Statement.