mirror of
https://github.com/macintoshplus/doc-fr.git
synced 2026-04-29 19:53:08 +02:00
118 lines
3.0 KiB
XML
118 lines
3.0 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
<!-- EN-Revision: e6553e39c9d6a20588c464b9af07cbdf07cfe07d Maintainer: yannick Status: ready -->
|
|
<!-- Reviewed: no -->
|
|
|
|
<refentry xml:id="function.radius-get-vendor-attr" xmlns="http://docbook.org/ns/docbook">
|
|
<refnamediv>
|
|
<refname>radius_get_vendor_attr</refname>
|
|
<refpurpose>Extrait un attribut spécifique au vendeur</refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<methodsynopsis>
|
|
<type>array</type><methodname>radius_get_vendor_attr</methodname>
|
|
<methodparam><type>string</type><parameter>data</parameter></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
Si <function>radius_get_attr</function> retourne
|
|
<constant>RADIUS_VENDOR_SPECIFIC</constant>,
|
|
<function>radius_get_vendor_attr</function> peut être appelé pour
|
|
déterminer le vendeur.
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="parameters">
|
|
&reftitle.parameters;
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry>
|
|
<term><parameter>data</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Données d'entrée.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="returnvalues">
|
|
&reftitle.returnvalues;
|
|
<para>
|
|
Retourne un tableau associatif contenant le type de l'attribut, le vendeur ainsi
|
|
que les données, ou &false; si une erreur survient.
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="examples">
|
|
&reftitle.examples;
|
|
<para>
|
|
<example>
|
|
<title>Exemple avec <function>radius_get_vendor_attr</function></title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
while ($resa = radius_get_attr($res)) {
|
|
|
|
if (!is_array($resa)) {
|
|
printf ("Erreur lors de la récupération de l'attribut : %s\n", radius_strerror($res));
|
|
exit;
|
|
}
|
|
|
|
$attr = $resa['attr'];
|
|
$data = $resa['data'];
|
|
printf("Attribut récupéré :%d %d octets %s\n", $attr, strlen($data), bin2hex($data));
|
|
if ($attr == RADIUS_VENDOR_SPECIFIC) {
|
|
|
|
$resv = radius_get_vendor_attr($data);
|
|
if (is_array($resv)) {
|
|
$vendor = $resv['vendor'];
|
|
$attrv = $resv['attr'];
|
|
$datav = $resv['data'];
|
|
printf("Récupération du vendeur de l'attribut :%d %d octets %s\n", $attrv, strlen($datav), bin2hex($datav));
|
|
}
|
|
|
|
}
|
|
}
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="seealso">
|
|
&reftitle.seealso;
|
|
<para>
|
|
<simplelist>
|
|
<member><function>radius_get_attr</function></member>
|
|
<member><function>radius_put_vendor_attr</function></member>
|
|
</simplelist>
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|