Topic: Almost working...but still setup-specific link stripping
Hey all...quick config question.
I'm using 1.1.8 and having a little problem that's driving me nuts. I am cleaning input from a SPAW editor instance in the admin area of a custom CMS. That is...this is not for a public forum, so I am only needing to clean up the html from the data-entry folks. Essentially, I just need to remove all styles and class attributes, but leave all other tags in place.
I've got htmLawed removing styles and class fine. I can't seem to get it to leave any URLs intact. Currently the best I can get is:
<a href="www.site.com" target="_blank">site</a>
to process as:
<a target="\" href="/">site</a>
I've tried $processed = htmLawed($content, $config,'a=*')...as well as just about everything I could find in the $config array.
htmLawedTest.php renders it just fine using the following config:
Array
(
[abs_url] => 0
[anti_link_spam] => 0
[anti_mail_spam] => 0
[anti_mail_spam1] => NO@SPAM
[balance] => 1
[base_url] => 0
[clean_ms_char] => 0
[deny_attribute] => Array
(
[style] => 0
[class] => 1
)
[elements] => Array
(
[p] => 0
[a] => 1
[b] => 2
)
[hexdec_entity] => 1
[hook] => 0
[hook_tag] => 0
[keep_bad] => 6
[lc_std_val] => 1
[named_entity] => 1
[no_deprecated_attr] => 1
[parent] => div
[safe] => 0
[schemes] => Array
(
[href] => Array
(
[aim] => 0
[feed] => 1
[file] => 2
[ftp] => 3
[gopher] => 4
[http] => 5
[https] => 6
[irc] => 7
[mailto] => 8
[news] => 9
[nntp] => 10
[sftp] => 11
[ssh] => 12
[telnet] => 13
)
[*] => Array
(
[file] => 0
[http] => 1
[https] => 2
)
)
[tidy] => 0
[unique_ids] => 1
[show_setting] => hlcfg
[and_mark] => 0
[cdata] => 3
[comment] => 3
[css_expression] => 0
[make_tag_strict] => 1
[style_pass] => 0
[xml:lang] => 0
)