@wildview,
1) The reason that the images are showing in the edit box are probably because you are clicking on the ‘Insert into Post’ button rather than the ‘Use as Featured Image’ link after uploading the file.
2) The Promotion Slider theme does not use the [raw] shortcode, nor does it insert it. It is likely that your theme or another plugin is inserting this for some reason. The best way to test this is to temporarily switch to the default TwentyTen or TwentyEleven theme, as well as to temporarily disable all other plugins and see if this is still an issue.
Thanks Micah,
Yes you are right on the first question and that did work thanks. However on number 2 it’s the promotion slider plugin that is causing the [raw][/raw] tags to show up on other theme shortcodes on my page. If I change themes the problem disappears, but only because the shortcodes don’t resolve for that theme. If I disable the promotion plugin all shortcodes for the theme work =) Bummer I guess I might not be able to use this plugin because it doesn’t appear to be compatible with the Karma theme if I want to still use all the themes shortcodes. Any ideas?
Here is the test page http://www.southlandbible.org/podcastBlog/test/
Thanks
So if you switch to the TwentyEleven theme what happens exactly? Do you see the [raw] shortcode on the page? Does everything work as expected?
I am pretty sure that what is happening is that the Karma theme is filtering and applying the [raw] shortcode somewhere along the way. It may just be a case of identifying where and disabling it in this specific instance.
Yep, when I switch to the TwentyEleven theme the Karma Theme Shortcodes (e.g. [hr_shadow]) just show up as text and the [Raw] tags are gone which is what I would expect since the Karma theme dynamically inserts the hidden [raw] tags as per the TrueTheme developers response below to my question. They are not sure why your plugin is showing the hidden tags either on the page, they should be hidden. Is there a way to fix this in your plugin?
Response from TrueTheme
“Sorry mate but these raw tags are dynamically inserted to prevent WordPress from auto-inserting paragraphs into the various elements of the page. We do not know why the Slider Plugin is showing these raw tags, it shouldn’t. There are many others that will work well. Here’s a great example of a different slider used by other Karma customers;”
Thanks for you help…
Ah… so where are the [hr_shadow] shortcodes being inserted?
Just in random places to break up the page. They are convenience shortcodes made available by the theme. BTW, it’s not just this shortcode it’s all of them that the theme has available. The problem I believe is your plugin is not doing something right that’s causing the [raw] tags
to be revealed from the higher end themes coupled with the lasted WP. I switched over to the easing slider and it works fine for me, I’ll keep watching to see if you ever get yours fixed to not do this =) I think as more people use some of the newer themes you will hear more complaints. Thanks again for you help and for the development of WP plugins.
I know this is an older topic, but I feel the need to jump in here. This is probably not a problem with the plugin – my opinion is that this is a problem with the theme. Other plugins can cause the theme to have the same issues with [raw] tags showing up around all their shortcodes.
In my case, the plugin I have installed shows a post’s content using a shortcode, and during this process it runs apply_filters on the_content, which seems to be the issue. The theme’s [raw] tags are implemented using a filter and applying it to the_content. For some reason they do not like it when other plugins run apply_filters on the_content.
I’m still looking for a solution. Right now I am using an if(is_page()) code to remove the raw filters on specific pages and have replaced the theme shortcodes on those pages with the html they output (mainly [hr_shadow]), but this is a messy solution and has its drawbacks.
@micah
Does the promotion slider plugin run apply_filters on the_content anywhere? If so, is their any chance of understanding what causes this incompatibility?
Here is how they implement their raw tags:
function my_formatter($content) {
$new_content = '';
$pattern_full = '{(\[raw\].*?\[/raw\])}is';
$pattern_contents = '{\[raw\](.*?)\[/raw\]}is';
$pieces = preg_split($pattern_full, $content, -1, PREG_SPLIT_DELIM_CAPTURE);
foreach ($pieces as $piece) {
if (preg_match($pattern_contents, $piece, $matches)) {
$new_content .= $matches[1];
} else {
$new_content .= wptexturize(wpautop($piece));
}
}
return $new_content;
}
remove_filter('the_content', 'wpautop');
remove_filter('the_content', 'wptexturize');
add_filter('the_content', 'my_formatter', 99);
@web2guru,
No, apply_filters is only used for custom filters within the plugin. Actually, the Promotion Slider doesn’t even do anything with the content… that is left up to the theme.
I see, interesting. The only reason I thought it was specific to the_content is because the plugin I’m using also runs apply_filters on the_excerpt and this doesn’t cause a problem.
Don’t want to hijack the thread, but here is some more info on these [raw] tags, I’d like to figure out what is going on, maybe we can develop a work-around.
Code posted here: http://www.wprecipes.com/disable-wordpress-automatic-formatting-on-posts-using-a-shortcode
Based on a plugin here: http://wordpress.org/support/topic/plugin-remove-wpautop-wptexturize-with-a-shortcode?replies=8
Issues discussed here: http://theandystratton.com/2011/shortcode-autoformatting-html-with-paragraphs-and-line-breaks
Guys,
i need help.
A featured slider was missing in WP 3.5.1 and was advised to put some codes in Functions php . After puting that code, i no longer have access to my admin site or dashboard.
this is a error message i am getting :
Parse error: syntax error, unexpected T_STRING in /home/mloga94/public_html/wp-content/themes/simple-catch/functions.php on line 135
This is a website i am building: http://www.logdeluxe.com
@mloga64, like I said on the other topic, you should create a new topic to get the best help. It gets confusing when we are tackling two separate and unrelated problems in the same context.
That being said, the other thread didn’t say anything about putting code in the functions.php. Not sure where you got that from (and again, start a new thread and maybe we can get this figured out). You will probably need to re-upload your theme’s original functions.php (or show us the code and changes).