Tags:
create new tag
, view all tags

Feature Proposal: New ENTITY Variable

Motivation

There is already a %ENCODE{ "..." type="entity" }% variable to entity-encode variables, which is used for example to properly escape content intended for html input fields. There is a possibility that the encoding fails in case the to-be-encoded text happens to have a sequence like "something" type="url" some more". E.g. the text could have a sequence that terminates the text early with a quote, followed by some text that confuses the ENCODE (or higher level content).

Description and Documentation

Add a new %ENTITY{...}% variable that does the same as %ENCODE{ "..." type="entity" }%. This avoids the potential issue of early termination of text if it contains a double quote.

Examples

Equivalents:

  • %ENCODE{ "%title{ default="" }%" type="entity" }%
  • %ENTITY{%title{ default="" }%}%

Impact

WhatDoesItAffect: Rendering

Implementation

-- Contributors: PeterThoeny - 2012-10-23

Discussion

Accepted by JerusalemReleaseMeeting2012x10x26

-- PeterThoeny - 2012-10-26

This is now implemented and documented in SVN trunk.

-- PeterThoeny - 2012-10-26

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r3 - 2012-10-26 - PeterThoeny
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.