From ea0377b93b3d290053fda7115929930b8c8d4d25 Mon Sep 17 00:00:00 2001 From: julieng Date: Thu, 11 Nov 2021 09:00:12 +0100 Subject: convert content to md --- .../web/xpath/functions/substring-before/index.md | 64 +++++++++++++--------- 1 file changed, 38 insertions(+), 26 deletions(-) (limited to 'files/fr/web/xpath/functions/substring-before') diff --git a/files/fr/web/xpath/functions/substring-before/index.md b/files/fr/web/xpath/functions/substring-before/index.md index f9ab5dcf01..0630ae0553 100644 --- a/files/fr/web/xpath/functions/substring-before/index.md +++ b/files/fr/web/xpath/functions/substring-before/index.md @@ -6,30 +6,42 @@ tags: translation_of: Web/XPath/Functions/substring-before original_slug: Web/XPath/Fonctions/substring-before --- -

{{ XsltRef() }} -


-La fonction substring-before() retourne retourne la partie d'une chaîne donnée précédant une sous-chaîne donnée. -

-

Syntaxe

-
substring-before( bottedefoin , aiguille )
-
-

Arguments

-
bottedefoin -
La chaîne à évaluer. Un extrait de cette chaîne sera retourné. -
-
aiguille -
La sous-chaîne à rechercher. Tout le contenu se trouvant avant la première occurrence de aiguille dans la chaîne bottedefoin sera retourné. -
-

Retour

-

Une chaîne. -

-

Exemples

- -
XPath Example Output
<xsl:value-of select="substring-before('1999/04/01','/')" /> 1999
substring-before('aa-bb','-') aa
substring-before('aa-bb','a') (empty string)
substring-before('aa-bb','b') aa-
substring-before('aa-bb','q') (empty string)
-

Définition

-

XPath 1.0, section 4.2. -

-

Support Gecko

-

Supportée. -

\ No newline at end of file + +La fonction `substring-before()` retourne retourne la partie d'une chaîne donnée précédant une sous-chaîne donnée. + +### Syntaxe + + substring-before( bottedefoin , aiguille ) + +### Arguments + +- `bottedefoin` + - : La chaîne à évaluer. Un extrait de cette chaîne sera retourné. + + + +- `aiguille` + - : La sous-chaîne à rechercher. Tout le contenu se trouvant avant la première occurrence de `aiguille` dans la chaîne `bottedefoin` sera retourné. + +### Retour + +Une chaîne. + +### Exemples + +| XPath Example | Output | +| -------------------------------------------------------------- | ---------------- | +| `` | `1999` | +| `substring-before('aa-bb','-')` | `aa` | +| `substring-before('aa-bb','a')` | `(empty string)` | +| `substring-before('aa-bb','b')` | `aa-` | +| `substring-before('aa-bb','q')` | (empty string) | + +### Définition + +[XPath 1.0, section 4.2](http://www.w3.org/TR/xpath#function-substring-before). + +### Support Gecko + +Supportée. -- cgit v1.2.3-54-g00ecf