note 77394 added to function.str-word-count
| From: | staticbit at sou dot eu | Date: | Tue, 28 Aug 2007 06:57:26 +0000 |
| Subject: | note 77394 added to function.str-word-count | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-129845@lists.php.net to get a copy of this message | ||
This function gets the list of words of a text, independently of the separator.
function my_str_word_count($texto)
{
$palavras_do_texto = array();
$rascunho = strip_tags($texto);
preg_match_all(
"/([a-zA-Zà âãáäèêéëìîÃïòôõóöùûúü
ñçýÿÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃ]+)/",
$rascunho, $palavras_do_texto);
return $palavras_do_texto[0];
}
----
Server IP: 69.147.83.197
Probable Submitter: 189.13.128.202
----
Manual Page -- http://www.php.net/manual/en/function.str-word-count.php
Edit -- https://master.php.net/note/edit/77394
Del: integrated -- https://master.php.net/note/delete/77394/integrated
Del: useless -- https://master.php.net/note/delete/77394/useless
Del: bad code -- https://master.php.net/note/delete/77394/bad+code
Del: spam -- https://master.php.net/note/delete/77394/spam
Del: non-english -- https://master.php.net/note/delete/77394/non-english
Del: in docs -- https://master.php.net/note/delete/77394/in+docs
Del: other reasons-- https://master.php.net/note/delete/77394
Reject -- https://master.php.net/note/reject/77394
Search -- https://master.php.net/manage/user-notes.php