Support » Fixing WordPress » Modifying html called by the_content

Viewing 3 replies - 1 through 3 (of 3 total)
  • No you can’t. I’ve come across this problem and never been able to fix it. Just have to modify your design to accomodate this… or use this:

    <?php echo substr(get_the_content(), 0, 150); ?>

    and change ‘150’ to however many characters you want to show. But it WILL output the html code if you cut it off in the middle of an image or link.

    Justin Tadlock


    WordPress God

    You’d have to float the time and comments line to the left and let the next paragraph wrap around it with CSS.

    It’s not something I recommend, unless you know that you’ll always use a paragraph as the first thing in your post.

    I’m only doing this for one category, using conditional tags, and I know that category will never have a post that starts with anything other than a paragraph. Thanks for your help, this worked really well.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Modifying html called by the_content’ is closed to new replies.