Project

General

Profile

Bug #101170

Updated by Helmut Hummel over 1 year ago

h2. Prerequisite 

 Given the following TypoScript: 

 <pre><code> 
 page = PAGE 
 page.10 = EXTBASEPLUGIN 
 page.10 { 
   extensionName = MyExt 
   pluginName = MyPlugin 
 } 

 </code></pre> 

 Given the default action referenced plugin is cached 


 h2. Expectation 

 The request in the plugin (and the ConfigurationManager has the currentContentObject attribute set. 

 h2. Actual behaviour 

 The currentContentObject is not set 

 h3. Conceptual considerations 

 During frontend rendering, all rendering is initiated with an instance of ContentObjectRenderer. 
 Since most rendering code depends on the current request, the request has always to be passed to 
 the ContentObjectRenderer, which can then pass it to rendering code it calls. 
 At the same time some rendering code depends also depends on the data, 
 that initiated the rendering (aka, the data that is contained in ContentObjectRenderer objects). 

 I see two options of how to pass the request *and* the ContentObjectRenderer object (cObj) to the rendering code: 

 # Extend the API to make both accessible directly 
 # Wrap the initiating cObj (the cObj that initiates rendering) into the request it holds as attribute 

 I suggested the latter in #100623, but what we merged in the end is incomplete and therefore somewhat broken (see above) 

Back