Project

General

Profile

Actions

Bug #51748

closed

PageRenderer->executePostRenderHook() does nothing when INT scripts are present

Added by Gabe Blair about 11 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2013-09-04
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.1
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

We have an extension that uses the following hook:

$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_pagerenderer.php']['render-postProcess']

This hook works by providing a handful of variables that can be modified by reference, and which are subsequently are populated in the page template. We use it to add a custom <HTML> tag to the site, to support html5boilerplate-type approaches to cross-browser compatibility.

I've found that this particular hook has no effect when there are INT scripts on the page, and was able to trace it back to the fact that the hook itself gets called only when Javascript and CSS are rendered. For INT scripts, this happens long after the initial page markers have been populated in the template (see PageRenderer->renderJavaScriptAndCss()).

If we truly need to provide the post-INT-script-rendered javascript/css to the hook, I would call this "Hard or Nightmare" complexity. If we can settle for just providing the initial set of CSS/javascript to the hook (which will probably be fine in most use cases), this isn't too bad. It will still allow for modification of <html> tags and other header-related hackery, which I'm guessing is what this hook is used for most.

Actions

Also available in: Atom PDF