示例#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;
 }