[TYPO3-mvc] RFC #12442: Add type json to escape viewhelper

Kevin Ulrich Moschallski km at 3digit.de
Fri Jan 21 17:02:10 CET 2011


Hi all,

this is a SVN patch request.

Type:
=====
Feature

Bugtracker:
===========
http://forge.typo3.org/issues/12442

Branches:
=========
trunk

Problem:
========
i suggest to add type json to the escape viewhelper.

Sometime you want to render json output with fluid and not with an own 
json view. The problem is that fluid also uses json like syntax, so if 
you want to add an object to a json string you run into a problem.

Imagine adding a link with the link viewhelper. It returns a sting with 
double quotes which need to be escaped for json.

Solution:
=========
I simply added type json to the escape viewhelper which returns the 
$value json_encode()'ed.

Regards,
Kevin



More information about the TYPO3-project-typo3v4mvc mailing list