mirror of
https://github.com/macintoshplus/doc-fr.git
synced 2026-03-25 17:32:07 +01:00
git-svn-id: https://svn.php.net/repository/phpdoc/fr/trunk@352057 c90b9560-bf6c-de11-be94-00142212c4b1
139 lines
4.3 KiB
XML
139 lines
4.3 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
<!-- EN-Revision: 92f1b8b177eb5730382abf9f27bae868f1bb636f Maintainer: yannick Status: ready -->
|
|
<!-- Reviewed: yes -->
|
|
<refentry xml:id="function.mb-substr" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
<refnamediv>
|
|
<refname>mb_substr</refname>
|
|
<refpurpose>Lit une sous-chaîne</refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<methodsynopsis>
|
|
<type>string</type><methodname>mb_substr</methodname>
|
|
<methodparam><type>string</type><parameter>string</parameter></methodparam>
|
|
<methodparam><type>int</type><parameter>start</parameter></methodparam>
|
|
<methodparam choice="opt"><type class="union"><type>int</type><type>null</type></type><parameter>length</parameter><initializer>&null;</initializer></methodparam>
|
|
<methodparam choice="opt"><type class="union"><type>string</type><type>null</type></type><parameter>encoding</parameter><initializer>&null;</initializer></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
Effectue une opération de type
|
|
<function>substr</function> basée sur le nombre de caractères.
|
|
La position est celle depuis le début de la &string;
|
|
<parameter>string</parameter>. La position du premier caractère
|
|
est &zero;, le second, un, etc...
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="parameters">
|
|
&reftitle.parameters;
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry>
|
|
<term><parameter>string</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
La chaîne à extraire depuis la sous-chaîne.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>start</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Si <parameter>start</parameter> est positif, la chaîne
|
|
retournée commencera au caractère numéro <parameter>start</parameter>,
|
|
dans la chaîne <parameter>string</parameter>. Le premier caractère
|
|
est numéroté zéro. En effet, dans la chaîne '<literal>abcdef</literal>',
|
|
le caractère à la position <literal>0</literal> est '<literal>a</literal>',
|
|
le caractère à la position <literal>2</literal> est '<literal>c</literal>',
|
|
et ainsi de suite.
|
|
</para>
|
|
<para>
|
|
Si <parameter>start</parameter> est négatif, la chaîne retournée
|
|
commencera au caractère numéro <parameter>start</parameter> à compter
|
|
de la fin de la chaîne <parameter>string</parameter>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>length</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Nombre maximal de caractères à utiliser
|
|
depuis <parameter>string</parameter>. Si ce paramètre
|
|
est omis, ou vaut <literal>NULL</literal>, tous les
|
|
caractères jusqu'à la fin de la chaîne seront extraits.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>encoding</parameter></term>
|
|
<listitem>
|
|
&mbstring.encoding.parameter;
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="returnvalues">
|
|
&reftitle.returnvalues;
|
|
<para>
|
|
<function>mb_substr</function> retourne la portion de la chaîne
|
|
<parameter>string</parameter> qui commence au caractère
|
|
<parameter>start</parameter> et a la longueur de
|
|
<parameter>length</parameter> caractères.
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="changelog">
|
|
&reftitle.changelog;
|
|
<informaltable>
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>&Version;</entry>
|
|
<entry>&Description;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
&mbstring.changelog.encoding-nullable;
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</refsect1>
|
|
|
|
<refsect1 role="seealso">
|
|
&reftitle.seealso;
|
|
<para>
|
|
<simplelist>
|
|
<member><function>mb_strcut</function></member>
|
|
<member><function>mb_internal_encoding</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
|
|
-->
|