Closed (fixed)
Project:
Token formatters
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
7 Aug 2012 at 01:05 UTC
Updated:
8 Sep 2012 at 17:28 UTC
Jump to comment: Most recent file
Comments
Comment #1
merlinofchaos commentedHere's a quick patch.
Comment #2
merlinofchaos commentedOk, I'm wrong. I do need this, because even after fixing imagecache_token to work with non-node entities, it only provides a URL, not an img tag, so I still need HTML to show the image.
Comment #3
dave reidModified the patch in #1 to use field_filter_xss(), allow the link text to also allow HTML, and fixed the $options['sanitize'] parameter for token replacement needed to be flipped since check_plain() is no longer getting called.
http://drupalcode.org/project/token_formatters.git/commit/2171ab8
Comment #5
hass commentedI tried using
[user:field_address]token that returns me an address field from addressfield / addressfield_tokens modules and I see below code in the node. How can we loosen the rules or can you add<span>to the good tags? May use a filter format that allows more tags?Example:
<span class="first-name">MyFirstname</span> <span class="last-name">MyLastname</span>MyStreet 63<span class="postal-code">12345</span> <span class="locality">MyCity</span><span class="country">Germany</span>Comment #6
dave reidAccording to http://api.drupal.org/api/drupal/modules%21field%21field.module/function... - span tags are allowed. Please file a new issue if needed.
Comment #7
hass commented#1778856: HTML span's check_plain'ed and div's filtered with [user:field_address] address field