array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'uk', ), 'this' => array ( 0 => 'function.yaz-es.php', 1 => 'yaz_es', 2 => 'Prepares for an Extended Service Request', ), 'up' => array ( 0 => 'ref.yaz.php', 1 => 'YAZ Функції', ), 'prev' => array ( 0 => 'function.yaz-error.php', 1 => 'yaz_error', ), 'next' => array ( 0 => 'function.yaz-es-result.php', 1 => 'yaz_es_result', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/yaz/functions/yaz-es.xml', ), 'history' => array ( ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); contributors($setup); ?>

yaz_es

(PECL yaz >= 0.9.0)

yaz_es Prepares for an Extended Service Request

Опис

yaz_es( resource $id , string $type , array $args ): void

This function prepares for an Extended Service Request. Extended Services is family of various Z39.50 facilities, such as Record Update, Item Order, Database administration etc.

Зауваження:

Many Z39.50 Servers do not support Extended Services.

The yaz_es() creates an Extended Service Request packages and puts it into a queue of operations. Use yaz_wait() to send the request(s) to the server. After completion of yaz_wait() the result of the Extended Service operation should be expected with a call to yaz_es_result().

Параметри

id

The connection resource returned by yaz_connect().

type

A string which represents the type of the Extended Service: itemorder (Item Order), create (Create Database), drop (Drop Database), commit (Commit Operation), update (Update Record), xmlupdate (XML Update). Each type is specified in the following section.

args

An array with extended service options plus package specific options. The options are identical to those offered in the C API of ZOOM C. Refer to the ZOOM » Extended Services.

Значення, що повертаються

Не повертає значень.

Приклади

Приклад #1 Record Update

<?php
$con = yaz_connect("myhost/database");
$args = array (
"record" => "<gils><title>some title</title></gils>",
"syntax" => "xml",
"action" => "specialUpdate"
);
yaz_es($con, "update", $args);
yaz_wait();
$result = yaz_es_result($id);
?>

Прогляньте також