]> git.wh0rd.org - tt-rss.git/commitdiff
note the source of highlighting routine
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Wed, 31 Jul 2013 10:54:22 +0000 (14:54 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Wed, 31 Jul 2013 10:54:22 +0000 (14:54 +0400)
include/functions.php

index 6ceb20adc470993b1a4c858b1aff98dff7d5ae45..4d24d0e264925a582229754884c30e2beb3c253c 100644 (file)
                if ($highlight_words) {
                        foreach ($highlight_words as $word) {
 
+                               // http://stackoverflow.com/questions/4081372/highlight-keywords-in-a-paragraph
+
                                $elements = $xpath->query('//*[contains(.,"'.$word.'")]');
 
                                foreach ($elements as $element) {