Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I whitelisted img[title]. Now, having an article containing , the value of the title attribute is stripped to " d" (so everything from the first character until the last colon seems to be stripped).
I could not see how to configure this, so I think it's a bug.
Comments
Comment #1
Peter Thomassen CreditAttribution: Peter Thomassen commentedAh, the img tag that I wrote above was stripped by the bugtracker. Here it is again, having < replaced by [:
I whitelisted img[title]. Now, having an article containing [img src="..." title="a: b, c: d"/], the value of the title attribute is stripped to " d" (so everything from the first character until the last colon seems to be stripped).
I could not see how to configure this, so I think it's a bug.
Comment #2
pschopf CreditAttribution: pschopf commentedI am having the same problem. I was adding a title like "Great image of Something. Source: photographer deserving credit" All that gets out is "photographer deserving credit"
is is possible that wysiwyg_filter_xss_bad_protcol is being run on the title text? It seems that everything in front of the colon is getting clipped.
Comment #3
patrickdepinguin CreditAttribution: patrickdepinguin commentedI have seen the same behavior without the WYSIWYG editor, and have created a new bug report for the core system here:
http://drupal.org/node/952964
Comment #4
markus_petrux CreditAttribution: markus_petrux commentedFrom my point of view, this feature works as designed, which is the same behavior as Drupal core itself. If it needs to be changed, then this is a feature request. Well, the bug could be in my mind, but I coded this module as if I was adding stuff to the Drupal core filter. The cause of this behavior is the "bad protocols" filtering (anything to the left of a colon should exist in a white list).
@patrickdepinguin: Thanks for chiming in and for opening that issue in the Drupal core queue. I'm interested to see what Drupal maintainers have to say before this behavior is changed here.
Comment #5
iStryker CreditAttribution: iStryker commentedThis is a core bug. Its been over 2 1/2 years. Marking this duplicate of #952964: String stripped from title and alt attribute if contains a colon