Ejemplo n.º 1
0
 public function __construct($API_KEY, $apiUrl)
 {
     $this->API_KEY = $API_KEY;
     $trimmedUrl = rtrim($apiUrl, "/");
     $this->apiUrl = $trimmedUrl . "/";
     $xh = new XMLHandler($this->getFeedUrl());
     $this->newsUrl = $xh->getHrefValue("news");
     $this->categoryUrl = $xh->getHrefValue("categoryDefinitions");
     $this->commentUrl = $xh->getHrefValue("comments");
     $this->feedName = $xh->getValue("name");
 }
 public function __construct($API_KEY, $apiUrl)
 {
     $this->API_KEY = $API_KEY;
     $trimmedUrl = rtrim($apiUrl, "/");
     $this->apiUrl = $trimmedUrl . "/";
     //JLog::add('load api handler.', JLog::INFO, 'com_braftonarticles');
     $xh = new XMLHandler($this->getFeedUrl());
     $this->newsUrl = $xh->getHrefValue("news");
     $this->categoryUrl = $xh->getHrefValue("categoryDefinitions");
     $this->commentUrl = $xh->getHrefValue("comments");
     $this->feedName = $xh->getValue("name");
 }
 /**
  * @param String $element
  * @return String
  */
 public static function getSetting($element)
 {
     $xh = new XMLHandler("../Classes/settings.xml");
     return $xh->getValue($element);
 }