[TYPO3-core] RFC: #11819: Feature: Add inline Javascript rendering type for TYPO3AJAX

Jeff Segars jsegars at alumni.rice.edu
Wed Sep 16 16:36:33 CEST 2009


Jeff Segars wrote:
> Hey guys,
> 
> This is a SVN patch request.
> 
> Type: Feature
> Bugtracker reference: http://bugs.typo3.org/view.php?id=11819
> Branch: trunk
> 
> Problem:
> The ajax handling in TYPO3AJAX supports several output formats (plain 
> text, JSON, XML) but inline Javascript would be a nice addition. iframes 
> are often used as a fallback for transporting AJAX data and rather than 
> returning pure JSON, you want the JSON contents embedded in a script tag 
> and assigned to a variable.
> 
> Solution:
> The attached patch adds a new rendering type to create this inline script.
> 
> 
> Additional Notes:
> This is particularly useful inside frontend editing, where the editing 
> form is now rendered inside an iframe. When editing is complete, we can 
> return inline Javascript inside the iframe and then pass that data back 
> to the parent page.
> 
> Thanks,
> Jeff

Thanks to Steffen, Steffen, and Peter for the reviews and testing. I've 
updated the patch to include CDATA and committed the attached v2 to 
trunk in r5945.

Thanks,
Jeff


More information about the TYPO3-team-core mailing list