本文整理汇总了PHP中TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::RECORDS方法的典型用法代码示例。如果您正苦于以下问题:PHP ContentObjectRenderer::RECORDS方法的具体用法?PHP ContentObjectRenderer::RECORDS怎么用?PHP ContentObjectRenderer::RECORDS使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer
的用法示例。
在下文中一共展示了ContentObjectRenderer::RECORDS方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getNewsletterPlain
/**
* get newsletter text plain - render from content elements of current pid
*
* @param $newsletter
* @return mixed
*/
private function getNewsletterPlain($newsletter)
{
$templateFile = $GLOBALS['TSFE']->tmpl->setup['config.']['baseURL'] . $GLOBALS['TSFE']->tmpl->setup['module.']['tx_pxcleverreach.']['settings.']['template.']['plain'];
// if template file not defined, return empty string
if (file_get_contents($templateFile) === false) {
return '';
}
// return all ce's of current pid
$rows = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows('*', 'tt_content', 'pid = ' . $newsletter->getPid() . $GLOBALS['TSFE']->sys_page->enableFields('tt_content'), '', 'sorting ASC');
$content = '';
foreach ($rows as $row) {
$content .= $this->contentObject->RECORDS(array('tables' => 'tt_content', 'source' => $row['uid']));
}
return str_replace('###CONTENT###', $this->clearContent($content), file_get_contents($templateFile, false));
}
示例2: render
/**
* Parse content element
*
* @param int UID des Content Element
* @return string Geparstes Content Element
*/
public function render($uid)
{
$this->cObj = $this->configurationManager->getContentObject();
$conf = array('tables' => 'tt_content', 'source' => $uid, 'dontCheckPid' => 1);
return $this->cObj->RECORDS($conf);
}
示例3: render
/**
* Parse a content element
*
* @param \int $uid UID of any content element
* @return \string Parsed Content Element
*/
public function render($uid)
{
$conf = array('tables' => 'tt_content', 'source' => intval($uid), 'dontCheckPid' => 1);
return $this->contentObject->RECORDS($conf);
}