]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/peoplesearch.php
move peoplesearchresults to its own module
[quix0rs-gnu-social.git] / actions / peoplesearch.php
index 615201c461f49c8c521e1530417b9bb4fc894422..14177fcf0d48cb996fb77d11f69e65104b9675c4 100644 (file)
@@ -86,33 +86,9 @@ class PeoplesearchAction extends SearchAction
         }
 
         $profile->free();
-        
+
         $this->pagination($page > 1, $cnt > PROFILES_PER_PAGE,
                           $page, 'peoplesearch', array('q' => $q));
     }
 }
 
-class PeopleSearchResults extends ProfileList
-{
-    var $terms = null;
-    var $pattern = null;
-    
-    function __construct($profile, $terms, $action)
-    {
-        parent::__construct($profile, $terms, $action);
-        $this->terms = array_map('preg_quote', 
-                                 array_map('htmlspecialchars', $terms));
-        $this->pattern = '/('.implode('|',$terms).')/i';
-    }
-    
-    function highlight($text)
-    {
-        return preg_replace($this->pattern, '<strong>\\1</strong>', htmlspecialchars($text));
-    }
-
-    function isReadOnly()
-    {
-        return true;
-    }
-}
-