@@ -150,7 +150,7 @@ function ascii_to_entities(string $str): string
150150 {
151151 /*
152152 If the $temp array has a value but we have moved on, then it seems only
153- fair that we output that entity and restart $temp before continuing. -Paul
153+ fair that we output that entity and restart $temp before continuing.
154154 */
155155 if (count ($ temp ) === 1 )
156156 {
@@ -281,7 +281,7 @@ function word_censor(string $str, $censored, string $replacement = ''): string
281281 // \w, \b and a few others do not match on a unicode character
282282 // set for performance reasons. As a result words like über
283283 // will not match on a word boundary. Instead, we'll assume that
284- // a bad word will be bookeneded by any of these characters.
284+ // a bad word will be bookended by any of these characters.
285285 $ delim = '[-_ \'\"`(){}<>\[\]|!?@#%&,.:;^~*+=\/ 0-9\n\r\t] ' ;
286286
287287 foreach ($ censored as $ badword )
@@ -402,7 +402,7 @@ function highlight_code(string $str): string
402402 *
403403 * @param string $str the text string
404404 * @param string $phrase the phrase you'd like to highlight
405- * @param string $tag_open the openging tag to precede the phrase with
405+ * @param string $tag_open the opening tag to precede the phrase with
406406 * @param string $tag_close the closing tag to end the phrase with
407407 *
408408 * @return string
@@ -460,7 +460,7 @@ function convert_accented_characters(string $str): string
460460 * Anything placed between {unwrap}{/unwrap} will not be word wrapped, nor
461461 * will URLs.
462462 *
463- * @param string $str the text string
463+ * @param string $str the text string
464464 * @param integer $charlim = 76 the number of characters to wrap at
465465 *
466466 * @return string
@@ -604,9 +604,9 @@ function ellipsize(string $str, int $max_length, $position = 1, string $ellipsis
604604 *
605605 * Removes slashes contained in a string or in an array
606606 *
607- * @param mixed string or array
607+ * @param mixed $str string or array
608608 *
609- * @return mixed string or array
609+ * @return mixed string or array
610610 */
611611 function strip_slashes ($ str )
612612 {
@@ -632,7 +632,7 @@ function strip_slashes($str)
632632 *
633633 * Removes single and double quotes from a string
634634 *
635- * @param string
635+ * @param string $str
636636 *
637637 * @return string
638638 */
@@ -651,7 +651,7 @@ function strip_quotes(string $str): string
651651 *
652652 * Converts single and double quotes to entities
653653 *
654- * @param string
654+ * @param string $str
655655 *
656656 * @return string
657657 */
@@ -677,7 +677,7 @@ function quotes_to_entities(string $str): string
677677 *
678678 * http://www.some-site.com/index.php
679679 *
680- * @param string
680+ * @param string $str
681681 *
682682 * @return string
683683 */
@@ -712,7 +712,7 @@ function reduce_multiples(string $str, string $character = ',', bool $trim = fal
712712 {
713713 $ str = preg_replace ('# ' . preg_quote ($ character , '# ' ) . '{2,}# ' , $ character , $ str );
714714
715- return ($ trim === true ) ? trim ($ str , $ character ) : $ str ;
715+ return ($ trim ) ? trim ($ str , $ character ) : $ str ;
716716 }
717717}
718718
@@ -814,7 +814,7 @@ function alternator(): string
814814
815815 $ args = func_get_args ();
816816
817- return $ args [($ i ++ % count ($ args ))];
817+ return $ args [($ i ++ % count ($ args ))];
818818 }
819819}
820820
@@ -829,13 +829,13 @@ function alternator(): string
829829 *
830830 * @param string $text String to search the phrase
831831 * @param string $phrase Phrase that will be searched for.
832- * @param integer $radius The amount of characters returned arround the phrase.
832+ * @param integer $radius The amount of characters returned around the phrase.
833833 * @param string $ellipsis Ending that will be appended
834834 *
835835 * @return string
836836 *
837837 * If no $phrase is passed, will generate an excerpt of $radius characters
838- * from the begining of $text.
838+ * from the beginning of $text.
839839 */
840840 function excerpt (string $ text , string $ phrase = null , int $ radius = 100 , string $ ellipsis = '... ' ): string
841841 {
0 commit comments