コード例 #1
0
ファイル: Script.php プロジェクト: kevinwan/xf
 /**
  * 在Scripts开头追加内容
  * @access public
  * @param string $str
  * @return XF_View_Helper_Header_Script
  */
 public function prependFile($str)
 {
     //防止与缓存中的路径重复
     $path = XF_View::getInstance()->getResourcePath();
     $str = str_replace($path, '', $str);
     array_unshift($this->_scripts, XF_String::text($path . $str));
     return $this;
 }
コード例 #2
0
ファイル: Title.php プロジェクト: kevinwan/xf
 /**
  * 在标题前方添加内容
  * @access public
  * @param string $str
  * @return View_Header_Title
  */
 public function prependTitle($str)
 {
     $this->_title = XF_String::text($str, false) . $this->_linkSymbol . $this->_title;
     return $this;
 }
コード例 #3
0
ファイル: Meta.php プロジェクト: kevinwan/xf
 /**
  * 在Meta尾部追加内容
  * @access public
  * @param string $str
  * @return XF_View_Helper_Header_Meta
  */
 public function appendMeta($str)
 {
     $this->_metas[] = XF_String::text($str);
     return $this;
 }
コード例 #4
0
ファイル: Link.php プロジェクト: kevinwan/xf
 /**
  * 在Link尾部追加内容
  * @access public
  * @param string $str
  * @return XF_View_Helper_Header_Link
  */
 public function appendLink($str)
 {
     $this->_links[] = XF_String::text($str);
     return $this;
 }