Tags break custom Excerpt function
Try removing the stripslashes() function.
Try removing the stripslashes() function.
Use the_excerpt() instead of the_content() – the_content() will only cut off if you do it manually.
The excerpt is a specific field in WordPress and is wholly unrelated to custom fields, which is why the excerpt stuff you tried has no effect. There is no built in way to trim custom fields, you have to do it manually with a bit of php: $length = 20; $text=”Lorem ipsum dolor sit amet, … Read more
…use WP as a engine where user can contribute their post and others can review it. I don’t think you need a plugin for what you want to do. Enable user registration on your WordPress site by going to WordPress Dashboard > Settings > General and checking Anyone can register option. Then right below it … Read more
I do not know why the WordPress powers that be decided to do it the way they did but they don’t consider the part before the <–more–> to be the same as the excerpt. Whether that makes sense or not is probably an irresolvable matter of perspective. I’d accept it and make do. The distinction … Read more
You need to use ‘the_content‘ filter function add_before_content($content) { return ‘Before content area ‘.$content; } add_filter(‘the_content’, add_before_content); It will still be inside the content div. If you want it outside the div you have to edit related template files i.e. single.php or templates/content-single.php. It all depends on which pages you want to apply it.
Is there a way to make it so that the user cannot delete certain things inside posts content? You need… A shortcode that will generate the content. This will let your users provide input but the markup can be rigidly controlled. Or a custom meta field. The markup around this can also be rigidly controlled, … Read more
My question is how can I automatically get the parent post content on every child Your code should work just like it is: if you have a parent and you add any number of children to this parent (wpse121567_get_cpt_hierarchy return ‘debate-child’ for them), your code will show the content of parent post. and if I … Read more
It is your css. I went into the your CSS and for .content-area. I took out the float left and then went into line 753 and took out the display:table. I am not sure on this theme but if it is using tables I would change it all to div’s .footer-sidebar::before, .footer-sidebar::after, .hentry::before, .hentry::after, .slider-direction-nav::before, … Read more
The easiest course of action would be to write manual excerpts instead of having the system generate them. Second, would be to wrap your “content that isn’t an excerpt” in a shortcode. If you look at the wp_trim_excerpt() function, which generates excerpts from post content, one of the first thing it does is strip shortcodes. … Read more