diff --git a/reference/strings/functions/strtr.xml b/reference/strings/functions/strtr.xml index 8eba430c4e..bab50c4710 100644 --- a/reference/strings/functions/strtr.xml +++ b/reference/strings/functions/strtr.xml @@ -1,5 +1,5 @@ - + @@ -39,7 +39,7 @@ $addr = strtr($addr, " - strtr can be called with only two + strtr may be called with only two arguments. If called with two arguments it behaves in a new way: from then has to be an array that contains string -> string pairs that will be replaced in the source @@ -47,18 +47,25 @@ $addr = strtr($addr, " longest possible match first and will *NOT* try to replace stuff that it has already worked on. - - Examples: - + + <function>strtr</function> example with two arguments "hi", "hi" => "hello"); -echo strtr("hi all, I said hello", $trans) . "\n"; + "hi", "hi" => "hello"); + echo strtr("hi all, I said hello", $trans); +?> ]]> - - This will show: "hello all, I said hi", + + This will show: + + + + This optional to and diff --git a/reference/strings/functions/wordwrap.xml b/reference/strings/functions/wordwrap.xml index 0e62b1539f..169798972b 100644 --- a/reference/strings/functions/wordwrap.xml +++ b/reference/strings/functions/wordwrap.xml @@ -1,5 +1,5 @@ - + @@ -20,14 +20,15 @@ Returns a string with str wrapped - at the column number specified by the (optional) + at the column number specified by the optional width parameter. The line is broken using the (optional) break parameter. wordwrap will automatically wrap at column - 75 and break using '\n' (newline) if width - or break are not given. + 75 and break using '\n' (newline) if + width or break + are not given. If the cut is set to 1, the string is @@ -51,23 +52,20 @@ $newtext = wordwrap( $text, 20 ); echo "$newtext\n"; ]]> - - - + This example would display: - - - + - - - + + <function>wordwrap</function> example @@ -78,23 +76,23 @@ $newtext = wordwrap( $text, 8, "\n", 1); echo "$newtext\n"; ]]> - - + This example would display: - - - + - + See also nl2br.