Somehow every time I create a new article using the NewsPublisher snippet my input HTML is filtered, tags like <object>, <code> and <blockquote> are stripped - while these are perfectly fine xHTML attributes. I’m not using any RTE (I don’t get why it copies the permissions of my manager account and not a separate for the front-end, but that’s a totally different matter), so it shouldn’t have any parsing if my idea is right; how can I fix this?
This was 7 years ago... but it saved my royal awkwardness today.
I could not bring myself to think that the culprit was NewsPublisher... but after some acts of hopelessness and unsavoury words ... I decided to dissect the rabbit:
ourmodx/core/components/newspublisher/model/newspublisher/newspublisher.class.php
$allowedTags = '<object><code><blockquote>
TinymceWrapper: Complete back/frontend content solution.
Harden your MODX site by
passwording your three main folders:
core, manager, connectors and renaming your
assets (thank me later!)
5 ways to sniff / hack your own sites; even with renamed/hidden folders, burst them all up, to see how secure you are not.
Hi Don, I'm not sure what you're saying.
The original code is:
$allowedTags = '<p><br><a><i><em><b><strong><pre><table><th><td><tr><img><span><div><h1><h2><h3><h4><h5><font><ul><ol><li><dl><dt><dd>';
You can see why object, code, and blockquote tags are getting stripped, but your proposed solution, if that's what it is, would strip everything *but* those three.
How about this?
$allowedTags = '<p><br><a><i><em><b><strong><pre><table><th><td><tr><img><span><div><h1><h2><h3><h4><h5><font><ul><ol><li><dl><dt><dd><object><blockquote><code>';
Sorry, there is an invisible ellipsis to that code. I meant, just add the missing tags.
$allowedTags = '<object><code><blockquote>...'
TinymceWrapper: Complete back/frontend content solution.
Harden your MODX site by
passwording your three main folders:
core, manager, connectors and renaming your
assets (thank me later!)
5 ways to sniff / hack your own sites; even with renamed/hidden folders, burst them all up, to see how secure you are not.
Of course. I should have seen that.
They'll be there in the next version, though it may be a while before it's released.