當前位置: 首頁>>代碼示例>>PHP>>正文


PHP modResource::getContent方法代碼示例

本文整理匯總了PHP中modResource::getContent方法的典型用法代碼示例。如果您正苦於以下問題:PHP modResource::getContent方法的具體用法?PHP modResource::getContent怎麽用?PHP modResource::getContent使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在modResource的用法示例。


在下文中一共展示了modResource::getContent方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: getContent

 public function getContent(array $options = array())
 {
     if ($this->xpdo instanceof modX) {
         $settings = $this->getContainerSettings();
         if ($this->xpdo->getOption('commentsEnabled', $settings, true)) {
             $this->getCommentsCall($settings);
             $this->getCommentsReplyCall($settings);
             $this->getCommentsCountCall($settings);
             $this->xpdo->setPlaceholder('comments_enabled', 1);
         } else {
             $this->xpdo->setPlaceholder('comments_enabled', 0);
         }
         $this->getTagsCall($settings);
         /** @var ArticlesContainer $container */
         $container = $this->getOne('Container');
         if ($container) {
             $container->getArchivistCall();
             $container->getLatestCommentsCall();
             $container->getLatestPostsCall();
             $container->getTagListerCall();
         }
     }
     $content = parent::getContent($options);
     return $content;
 }
開發者ID:raadhuis,項目名稱:modx-basic,代碼行數:25,代碼來源:article.class.php

示例2: getContent

 public function getContent(array $options = array())
 {
     $content = parent::getContent($options);
     $language = $this->getLanguage();
     $year = date('Y');
     if (!($content = $this->lookForTranslations('content'))) {
         $content = parent::getContent($options);
     }
     return $content;
 }
開發者ID:bendasvadim,項目名稱:modTranslatedDocument,代碼行數:10,代碼來源:modtranslateddocument.class.php

示例3: getContent

 public function getContent(array $options = array())
 {
     $content = '<div class="postBody">' . parent::getContent($options) . '</div>';
     $conversation = $this->class_key . '-' . $this->id;
     $properties = $this->getProperties('modxtalks');
     $properties = array_merge(array('conversation' => $conversation), $properties);
     $out = '';
     foreach ($properties as $key => $property) {
         $out .= "&{$key}=`{$property}`";
     }
     $content .= '[[$chankModxTalksStreak]][[!modxTalks?' . $out . ']]';
     return $content;
 }
開發者ID:jolichter,項目名稱:modxTalks,代碼行數:13,代碼來源:commentsmodxtalks.class.php

示例4: getSourceFile

 /**
  * Get the absolute path to the static source file represented by this instance.
  *
  * @param array $options An array of options.
  * @return string The absolute path to the static source file.
  */
 public function getSourceFile(array $options = array())
 {
     if (empty($this->_sourceFile)) {
         $filename = parent::getContent($options);
         if (!empty($filename)) {
             $array = array();
             if ($this->xpdo->getParser() && $this->xpdo->parser->collectElementTags($filename, $array)) {
                 $this->xpdo->parser->processElementTags('', $filename);
             }
         }
         if (!file_exists($filename)) {
             $this->_sourcePath = $this->xpdo->getOption('resource_static_path', $options, $this->xpdo->getOption('base_path'));
             if ($this->xpdo->getParser() && $this->xpdo->parser->collectElementTags($this->_sourcePath, $array)) {
                 $this->xpdo->parser->processElementTags('', $this->_sourcePath);
             }
             $this->_sourceFile = $this->_sourcePath . $filename;
         } else {
             $this->_sourceFile = $filename;
         }
     }
     return $this->_sourceFile;
 }
開發者ID:ChrstnMgcn,項目名稱:revolution,代碼行數:28,代碼來源:modstaticresource.class.php

示例5: getContent

 /**
  * @param array $options
  *
  * @return string
  */
 public function getContent(array $options = array())
 {
     $content = parent::getContent($options);
     return $content;
 }
開發者ID:soulcreate,項目名稱:Tickets,代碼行數:10,代碼來源:ticketssection.class.php

示例6: getContent

 /**
  * Get, process and encode the content of this Resource
  * @return void
  */
 public function getContent()
 {
     $content = $this->resource->getContent();
     $this->setPlaceholder('content', $this->hm->getTpl('widgets/text', array('text' => $this->safe($content, true))));
 }
開發者ID:rossng,項目名稱:HandyMan,代碼行數:9,代碼來源:view.class.php


注:本文中的modResource::getContent方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。