amironov73 / phpirbis
Simple client for IRBIS64
Installs: 276
Dependents: 0
Suggesters: 0
Security: 0
Stars: 6
Watchers: 4
Forks: 2
Open Issues: 2
Language:JavaScript
Requires
- php: >= 5.4.0
- ext-curl: *
- ext-json: *
- ext-pdo: *
- ext-sockets: *
README
Universal client software for IRBIS64 library automation system (ManagedIrbis ported to PHP 5). Available on Packagist.
Now supported PHP 5.4+ on Windows (Open Server), MacOS X (MAMP and MAMP Pro) and Ubuntu Linux.
require __DIR__ . '/../vendor/autoload.php'; $connection = new Irbis\Connection(); $connectString = 'host=127.0.0.1;user=librarian;password=secret;'; $connection->parseConnectionString($connectString); if (!$connection->connect()) { echo "Can't connect!\n"; echo Irbis\describe_error($connection->lastError); die(1); } $found = $connection->search('"A=Byron, George$"'); echo "<p>Records found: " . count($found) . "</p>\n"; foreach ($found as $mfn) { $record = $connection->readRecord($mfn); $title = $record->fm(200, 'a'); echo "<p><b>Title:</b> {$title}<br/>"; $description = $connection->formatRecord("@brief", $mfn); echo "<b>Description:</b> {$description}</p>\n"; } $connection->disconnect();