мне нужно подсчитать количество слов в пределах диапазона тега ... Текст, как правило, похожи наподсчета слов в тег диапазона
This<span class="highlight_word"> function is useful to highlight words from a simple non-html </span>text.The<span class="highlight_word"><span class="highlight_word"><span class="highlight_word"> regular expression, as a pattern, can match all kinds of text strings helping your application </span></span>validate, compare, compute, decide etc\. </span>With<span class="highlight_word"><span class="highlight_word"><span class="highlight_word"> the temperature up on keywords and searches, many sites have opted </span></span>for highlighting the keywords from their searches\. This can be useful for quickly finding relavant words withing large pages of text\. </span>
Может кто-нибудь наставит меня о том, как подсчитать количество слов в теги span.
Благодаря
Как вы хотите, граф вернулся? Один счетчик (т. Е. Слова xyz между суммами тегов span), количество в наборе тегов span? Как вы хотите, чтобы вложенные теги обрабатывались? ' слов больше слов больше' Что вы ожидаете от этого примера? – Leigh