php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #64861 [DE] Error in strripos() German translation
Submitted: 2013-05-16 14:33 UTC Modified: 2020-04-03 07:16 UTC
From: eproskawetz at t-online dot de Assigned: cmb (profile)
Status: Closed Package: Translation problem
PHP Version: 5.5.0RC1 OS: Windows
Private report: No CVE-ID: None
 [2013-05-16 14:33 UTC] eproskawetz at t-online dot de
Description:
------------
---
From manual page: http://www.php.net/function.strripos#refsect1-function.strripos-parameters
---


Test script:
---------------
 offset

    Wenn angegeben, wird die Suche diese Anzahl an Buchstaben vom Anfang des Strings gezählt stoppen. Wenn der Wert negativ ist, startet die Suche stattdessen diese Anzahl an Zeichen vom Ende des Strings aus.

This says, that the search stop at the position offset if the value is positiv and if the value is negativ it starts at strlen-offset. Correct would be:

Wenn angegeben, wird die Suche diese Anzahl an Buchstaben vom Ende des Strings gezählt stoppen. Wenn der Wert negativ ist, endet die Suche stattdessen diese Anzahl an Zeichen vom Anfang des Strings aus.


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-05-16 19:53 UTC] aharvey@php.net
-Summary: Documentation bug +Summary: [DE] Error in strripos() German translation -Package: Documentation problem +Package: Translation problem
 [2015-03-02 19:35 UTC] cmbecker69 at gmx dot de
> This says, that the search stop at the position offset if the
> value is positiv and if the value is negativ it starts at
> strlen-offset.

Yes. And that is how the $offset parameter is supposed to work,
see the examples given for strrpos().

The German translation is correct, albeit somewhat clumsy.
 [2015-04-06 21:44 UTC] c dot jantz at vations dot de
The wording is super confusing here. 

What about this alternative: 
Wenn angegeben beginnt die Suche bei angegebener Position von Beginn des Strings an gezählt. 
Sollte der Wert negativ sein startet die Suche selbige Anzahl von Zeichen vor Ende des Strings und sucht rückwärts.
 [2015-04-06 21:59 UTC] cmb@php.net
> The wording is super confusing here.

After having reconsidered this issue in the meantime, I have to
agree. It appears to me that the original needs improvement, too.
Actually, the search always works backwards[1] (what might be
regarded as an implementation detail, but searching forwards for
the last occurance wouldn't make sense). Describing it this way,
might simplify the explanation. See also bug #50317.

Anyhow, related to bug #68010.

[1] <http://lxr.php.net/xref/PHP_5_6/ext/standard/string.c#1981>
 [2015-04-12 20:44 UTC] cmb@php.net
Related to bug #66563.
 [2020-04-03 07:16 UTC] cmb@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: cmb
 [2020-04-03 07:16 UTC] cmb@php.net
This issue has been resolved in the meantime.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 14:01:32 2024 UTC