2012-05-16, 04:41:52
I noticed a issue with content filters and certain setups.
I like the ability to use pages as components, say in a sidebar or footer or whatever.
This has the obvious advantage of having wysiwyg editor for these.
I've seen others post about this as well.
So I use dynpages with a component to grab the content of a slug.
Usually with get_i18n_content();
The problem is that some plugins use content filters that let you select a slug and perform actions on that slug with a content filter.
The problem is that these trigger on all content filters running on the same page request.
So all content gets replaced not just the content for the actual slug.
I am trying to figure out a way around this. The only thing i can come up with besides not doing things this way, I prefer plugins that use inline replacements instead, but slug selection has its merits as its less steps for users in some instances.
Perhaps it could be possible for content filter callback functions to be called with an argument specifying the contents actual slug. I can't think of any other way.
I mean maybe content filters shouldn't be used to replace or insert content at all, only for editing content.
Perhaps this is a misuse of content plugins to begin with.
Perhaps we can use something else such as dynamic pages.
Perhaps plugin authors could allow no slugs to be selected and then provide an inline replacement string as an alternate method.
ideas?
I like the ability to use pages as components, say in a sidebar or footer or whatever.
This has the obvious advantage of having wysiwyg editor for these.
I've seen others post about this as well.
So I use dynpages with a component to grab the content of a slug.
Usually with get_i18n_content();
The problem is that some plugins use content filters that let you select a slug and perform actions on that slug with a content filter.
The problem is that these trigger on all content filters running on the same page request.
So all content gets replaced not just the content for the actual slug.
I am trying to figure out a way around this. The only thing i can come up with besides not doing things this way, I prefer plugins that use inline replacements instead, but slug selection has its merits as its less steps for users in some instances.
Perhaps it could be possible for content filter callback functions to be called with an argument specifying the contents actual slug. I can't think of any other way.
I mean maybe content filters shouldn't be used to replace or insert content at all, only for editing content.
Perhaps this is a misuse of content plugins to begin with.
Perhaps we can use something else such as dynamic pages.
Perhaps plugin authors could allow no slugs to be selected and then provide an inline replacement string as an alternate method.
ideas?