getPiwikVersion() public method

public getPiwikVersion ( )
示例#1
0
文件: Client.php 项目: piwik/piwik
 /**
  * @param  $pluginOrThemeName
  * @throws Exception
  * @return string
  */
 public function getDownloadUrl($pluginOrThemeName)
 {
     $plugin = $this->getPluginInfo($pluginOrThemeName);
     if (empty($plugin['versions'])) {
         throw new Exception('Plugin has no versions.');
     }
     $latestVersion = array_pop($plugin['versions']);
     $downloadUrl = $latestVersion['download'];
     return $this->service->getDomain() . $downloadUrl . '?coreVersion=' . $this->environment->getPiwikVersion();
 }
示例#2
0
 public function setEnvironment(Environment $environment)
 {
     $this->setPiwikVersion($environment->getPiwikVersion());
     $this->setPhpVersion($environment->getPhpVersion());
 }