diff options
Diffstat (limited to 'lib/ocsclient.php')
-rwxr-xr-x | lib/ocsclient.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/ocsclient.php b/lib/ocsclient.php index d830a4f3e7e..9ad9ef21c66 100755 --- a/lib/ocsclient.php +++ b/lib/ocsclient.php @@ -199,7 +199,7 @@ class OC_OCSClient{ * * This function returns a list of all the knowledgebase entries from the OCS server */ - public static function getKnownledgebaseEntries($page,$pagesize){ + public static function getKnownledgebaseEntries($page,$pagesize,$search=''){ if(OC_Config::getValue('knowledgebaseenabled', true)==false){ $kbe=array(); $kbe['totalitems']=0; @@ -208,7 +208,8 @@ class OC_OCSClient{ $p= (int) $page; $s= (int) $pagesize; - $url=OC_OCSClient::getKBURL().'/knowledgebase/data?type=150&page='.$p.'&pagesize='.$s; + if($search<>'') $searchcmd='&search='.urlencode($search); else $searchcmd=''; + $url=OC_OCSClient::getKBURL().'/knowledgebase/data?type=150&page='.$p.'&pagesize='.$s.$searchcmd; $kbe=array(); $xml=@file_get_contents($url); |