Im not a programmer, but I do need anchors to work on my site. Currently with HTML purifier, this isnt possible as its stripping the name attribute in the html output. I have EnableId on and have cleared my cache to no avail. I have looked all over the net, I cant find a solution that doesnt involve sifting through large amounts of Jargon. Could you please provide a lamers guide to fixing this issue? I dont have large amounts of time to figure this out and if neccesary Im willing to pay to get this done.
From what I can tell, many have this problem and it would be nice to see something friendly and conclusive to fix this.
Please help!

regards,
Michael

Comments

ezyang’s picture

Status: Active » Fixed

Set the HTML.Attr.Name.UseCDATA directive to be on.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

mcartmel’s picture

Status: Closed (fixed) » Active

Hi,
In advanced options, I've enabled UseCDATA and EnableID, but the name attribute is still being stripped. Can you clarify what other options need to be set to allow anchors?

ezyang’s picture

Status: Active » Postponed (maintainer needs more info)

Have you set any other configuration options?

agentili’s picture

I have the same problem HTMLpurifier strips the anchor name attribute. I tried to configure HTMLpurifier from the Site configuration › Input formats › Full HTML >Advanced configuration options and set the Attr.Name.UseCDATA to yes but the anchor name get stripped.

alexpott’s picture

I had this problem too. I fixed it by clearing the site's caches after I set Attr.Name.UseCDATA to yes then the name attribute is allowed.

Basically it seems that the moment you make a change to html purifier's config you need to clear it's cache (this can be done of the it's settings form).

ezyang’s picture

Title: how to allow anchor name attribute » Configuration change does not clear the cache
Component: Code » User interface
Category: support » bug
Priority: Major » Normal
Status: Postponed (maintainer needs more info) » Needs work

Reclassifying bug. It's not clear to me if it's better to automatically clear the cache on a configuration change, or just tell the user that old entries won't automatically get updated. Clearing the cache could cause performance problems.

ezyang’s picture

Version: 6.x-2.3 » 7.x-2.x-dev

Bumped milestone, probably won't fix this for 6.x.

heddn’s picture

Status: Needs work » Fixed

This is resolved by a note in the text filter. See: http://drupalcode.org/project/htmlpurifier.git/commit/7524be

Status: Fixed » Closed (fixed)
Issue tags: -html purifier, -anchors not working, -name attribute disappears

Automatically closed -- issue fixed for 2 weeks with no activity.