コード例 #1
0
ファイル: Content.php プロジェクト: soitun/wifidog-auth
 /** Handle replacements of hyperlinks for clickthrough tracking (if appropriate) */
 protected function replaceHyperLinks(&$html)
 {
     /* Handle hyperlink clicktrough logging */
     if ($this->getLoggingStatus() == true) {
         $html = HyperLinkUtils::replaceHyperLinks($html, $this->log_as_content);
     }
     return $html;
 }
コード例 #2
0
ファイル: HyperLink.php プロジェクト: cnlangzi/wifidog-auth
 /**
  * Retreives the user interface of this object.
  *
  * Anything that overrides this method should call the parent method with
  * it's output at the END of processing.
  * @return string The HTML fragment for this interface
  */
 public function getUserUI()
 {
     // Init values
     $html = '';
     $url = $this->getString();
     if (HyperLinkUtils::validateURL($url)) {
         $html = "<a href='{$url}'>{$url}</a>\n";
     } else {
         $html = $url . " " . _("(invalid URL)") . "\n";
     }
     /* Handle hyperlink clicktrough logging */
     $html = $this->replaceHyperLinks($html);
     $this->setUserUIMainDisplayContent($html);
     return Content::getUserUI();
 }