0
votes

Without knowingly having changed something in the configuration or templates, I can't output content elements in the detail view of news-articles.

1/1) #1253191023 TYPO3Fluid\Fluid\Core\ViewHelper\Exception

TypoScript object path "lib.tx_news.contentElementRendering" does not exist

I have this configuration:

typo3conf/ext/news/Configuration/TypoScript/setup.txt

# Rendering of content elements in detail view
lib.tx_news.contentElementRendering = RECORDS
lib.tx_news.contentElementRendering {
    tables = tt_content
    source.current = 1
    dontCheckPid = 1
}

typo3conf/ext/site_package/Resources/Plugin/News/Templates/News/Detail.html

<f:if condition="{newsItem.contentElements}">
 <!-- content elements -->
 <f:cObject typoscriptObjectPath="lib.tx_news.contentElementRendering">
  {newsItem.contentElementIdList}
 </f:cObject>
</f:if>

So it looks to me as it is what is recommended in the docs: https://docs.typo3.org/p/georgringer/news/master/en-us/Tutorials/Templates/RenderContentElements/Index.html

Typo3 version: 10.4.12

News version: 8.5.2

I can't figure out why I can't output content-elements in news-articles all of the sudden.

Can anyone help?

1
Please mention your TYPO3 and News version.Mathias Brodala
Typo3 10.4.12 News 8.5.2user838531
Have you included the static TypoScript of EXT:news in your (TypoScript-)Template? docs.typo3.org/p/georgringer/news/master/en-us/…Julian Hofmann
You are right, the static template was not included... Thank you. How can I award this question to you?user838531

1 Answers

1
votes

If lib.tx_news.contentElementRenderingis not defined, most likely you've forgotten to include the static TypoScript Template of EXT:news.

News system - Installation:

Preparation: Include static TypoScript

The extension ships some TypoScript code which needs to be included.

  1. Switch to the root page of your site.
  2. Switch to the Template module and select Info/Modify.
  3. Press the link Edit the whole template record and switch to the tab Includes.
  4. Select News (news) at the field Include static (from extensions): Screenshot of TYPO3 backend's "Include static" field