My the_content filter kills gallery shortcode and I dont know where the problem is…
I can add just blank the_content filter and gallery disappear from the content and there is just text. I am using the_content filter:
function test($data){
echo $data;
}
add_filter('the_content', 'test');
Any suggestion how to fix it?
This is a common mistake, you just need to return the information to keep applying new filters, so change the function tho this:
You can get more information at: http://codex.wordpress.org/Plugin_API/Filter_Reference/the_content
You can just pass the modified content within the do_shortcode() to keep the short code functionality working after doing your stuff with the content.