solarbird: Brigitte Lindholm from Overwatch (brigitte)
[personal profile] solarbird

Okay, so if you’re one of the 200ish people still using JournalPress, or you want to start using JournalPress to bring your entries over to Dreamwidth, you may know that WordPress “featured images” work very badly over there. And that tends to make you not want to use them – or that’s certainly what happens with me – even if they’re very nice in your theme, and/or if you want them to show up in your blog’s ActivityPub feed.

There is a trivial solution, if you have access to your plugin directory.

All you have to do is edit [bloghome]/wp-content/plugins/journalpress/lib/jpposts.class.php and comment out (or remove entirely) these four lines of code:

    // do we have a featured image?
    if($imgID = get_post_thumbnail_id($this->post->ID)){
      $img = wp_get_attachment_image($imgID, 'full', false, array('style' => 'max-width: 100%; margin: 0 auto; display: block;'));
      if($img){ $the_event = $img . $the_event; }
    }

Comment out/delete and save. That’s it. It’s that easy. (And, thankfully, documented in comments so easy to find!) Comment out (or remove) that code and featured images won’t be detected by JournalPress at all, and won’t mess up your lovely Dreamwidth journal or your followers’ reading lists.

Posted via Solarbird{y|z|yz}, Collected.

June 2025

S M T W T F S
1 234 5 67
891011 1213 14
15 16 1718192021
22232425262728
2930     

Most Popular Tags