Piwik\Plugins\Marketplace\Api\Client::searchForThemes PHP 메소드

searchForThemes() 공개 메소드

public searchForThemes ( $keywords, $query, $sort, $purchaseType )
    public function searchForThemes($keywords, $query, $sort, $purchaseType)
    {
        $response = $this->fetch('themes', array('keywords' => $keywords, 'query' => $query, 'sort' => $sort, 'purchase_type' => $purchaseType));
        if (!empty($response['plugins'])) {
            return $this->removeNotNeededPluginsFromResponse($response);
        }
        return array();
    }

Usage Example

예제 #1
0
파일: Plugins.php 프로젝트: piwik/piwik
 public function searchPlugins($query, $sort, $themesOnly, $purchaseType = '')
 {
     if ($themesOnly) {
         $plugins = $this->marketplaceClient->searchForThemes('', $query, $sort, $purchaseType);
     } else {
         $plugins = $this->marketplaceClient->searchForPlugins('', $query, $sort, $purchaseType);
     }
     foreach ($plugins as $index => $plugin) {
         $plugins[$index] = $this->enrichPluginInformation($plugin);
     }
     return array_values($plugins);
 }