Featured Images not importing - min_width + min_height constants ignored

This is a recurrence of a similar problem from before - some images are not being imported - here is the low down:

The RSS URL:

http://www.greenheartshop.org/blog/feed/

Original posts with a featured image, but no other content images are not re-imported with a featured image:

Original:
http://greenhearttravel.org/global-greenheart-initiative/greenheart-clubgrant/3-reasons-to-join-the-greenheart-club

Auto-blogged result has no image ( all posts link back out to the original, so no way to send a URL to view ).

If I edit the original and add a small 150x150 in the content space - this is pulled in and set as the featured image - but I have the following in the wp-config.php:

// autoblog settings ##
define( 'AUTOBLOG_FEATURED_IMAGE_MIN_WIDTH', 292);
define( 'AUTOBLOG_FEATURED_IMAGE_MIN_HEIGHT', 181);

So, this small image should not be included.

I only have the "Featured Image" add-on active of the two image options.

In the feed settings I have the following option checked:

- Find the first image withing ( within? ) content of a feed item

This site is live and uses a custom theme and a number of plugins - there is, as with most of these cases - no chance to swap to 2012 and turn the other plugins off.

Any extra info required - please ask.

  • Alexander
    • DEV MAN’s Mascot

    Hi @Q Studio,

    I've just tested that feed and it worked ok for me. Keep in mind that articles are only imported once based on the most recent article in the feed.

    So you won't be able to reimport if you didn't get the images the first time. You would need to delete all the feed entries, then also remove them from the trash.

    Also, I've taken a look and I don't see those constants available in the Autoblog code. Would you mind letting me know where you got those?

    Best regards,

  • Ray Q
    • Site Builder, Child of Zeus

    Hi Alex,

    Thanks for your reply.

    I'm well aware of the process to delete and empty trash - I've had long running issues with this plugin.

    Please can you clarify what you mean with:

    I don't see those constants available in the Autoblog code

    These constants "were" available at one point to control the images - I think they might even have been added following a previous issue I reported with small images being imported.

    This plugin has been working well the last few months - with few issues - nothing much has changed on the site in question - but the issue remains.

    How can we progress?

  • Alexander
    • DEV MAN’s Mascot

    Hi @Q Studio,

    I'm sorry about the delay here. I've checked back to older versions, and I found out that this particular constant was removed in the latest version. I'm not sure why this change was made, but there were some changes made to how the add on works.

    I'll touch base with the plugin developer on this issue to see if he can advise on it.

    Best regards,

  • Ray Q
    • Site Builder, Child of Zeus

    Thanks for your reply.

    Was this change noted in the changelog or any other place?

    If not, why not - this is an important feature which I "was" using..?

    Sorry, but I've got to say - 1 week later to say that you're still waiting for the plugin developer - I've seen that answer too many times on this site... perfectly acceptable on a free plugin - simple not acceptable on a site that sells itself with the premise of being the single go-to place for WP support..

  • Alexander
    • DEV MAN’s Mascot

    Hi @Q Studio,

    It was noted in the change log, but didn't specifically mention the define statements. Basically the a good portion of that add-on was rewritten.

    I'm still waiting to hear back from the developer, but it could be a bit delayed here as it's the holidays.

    Best regards,

  • Eugene Manuilov
    • Syntax Hero

    Hi @Q Studio

    Sorry for delay. Could you please make a screenshot of your greenheartshop feed settings (especially featured image part)?

    I am finishing working on the new version of the plugin. The new version contains a number of improvements, bug fixes and new features. Some of these improvements/fixes are related to images importing part (including featured image).

    During those improvements/fixes the featured image import addon has been reworked. The ability to import image from media:thumbnail tag was added, but removed ability to import featured images which have specific dimension. The reason why it has been removed is in performance issue, which appears because of a need to download images and calculate their dimensions for each post in a feed to find proper image.

    The most proper way to import featured image is to use a value of media:thumbnail tag or the first image in a feed item. It is logically that the featured image will be most likely the first image in the content.

    However if you think that it makes sense for you to use dimensions to determine featured image, then I could review the addon and add back this functionality. So could you please explain me how do you see it should work in the plugin? I will try to add it.

    Regards,
    Eugene

  • Ray Q
    • Site Builder, Child of Zeus

    Hi Eugine,

    Thanks for your reply.

    Please find attached a screen grab of the settings for the GH Shop feed.

    And a second grab of the add-on configuration screen.

    I'd like to ask also - how to add the "media:thumbnail" parameter to an RSS feed - some of these feeds will come from WP, but they also come from a wide range of other sources - and I will have control over very few of them?

    Ray

  • Eugene Manuilov
    • Syntax Hero

    Hi @Q Studio

    I can see from your settings that the first image in a content should be imported as featured image. Does it work for you right now?

    I'd like to ask also - how to add the "media:thumbnail" parameter to an RSS feed - some of these feeds will come from WP, but they also come from a wide range of other sources - and I will have control over very few of them?

    If you can't control them, then you can't add media:thumbnail to those feeds. What feeds can you control? Are they WP feeds?

    Regards,
    Eugene

  • Ray Q
    • Site Builder, Child of Zeus

    Hi Eugene,

    Did you make any change - has there been a new release - why do you expect it to be working now - I have not changed any settings?

    I will have control over some of the feeds, which will come from WP sites.

    Cheers

  • Ray Q
    • Site Builder, Child of Zeus

    Hi Eugene,

    I started this support request 4 weeks ago - my client wants to know when this is going to resolved - and to be honest, so do I - can you please let me know when the new release will be available or what else is going on?

  • Eugene Manuilov
    • Syntax Hero

    Hi @Q Studio

    Sorry for delay. I am a bit confused what the issue is right now. Could you please explain me what is not working for you? From your settings I can see that the first image (within feed item content) has to set as featured image (no matter of its size). Does it work right now?

    The release is 99% ready and I will publish release candidate on the forum in a couple of days. So you will be able to grab it.

    Regards,
    Eugene

  • Ray Q
    • Site Builder, Child of Zeus

    Hi Eugene,

    Thanks for the offer - however, I don't understand why you require FTP access?

    I'm also hesitant to hand-out admin credentials - this is a live site which belongs to an important client - and with all respect, I don't know you at all.

    I am an experienced developer - I can provide you will all the info you require and complete any steps you need - but I must protect the security of my clients website.

    Is there no other method to achieve what you need to do, without you having full access to my clients website?

    Thanks

  • Eugene Manuilov
    • Syntax Hero

    I need admin credentials to check whether or not the plugin works on your site. There could be just a need to adjust some settings or enable additional addon to make it working. Or in case if the plugin is setup correctly but works improperly I need ftp to troubleshoot the plugin and find out a reason of it.

    So if you can't or don't want to give it, lets continue via forum. I just wanted to hurry up the progress.

    Nevertheless could you activate Image Import addon, deactivate Debug Image Import addon and test again?

  • Ray Q
    • Site Builder, Child of Zeus

    Hi Eugene,

    I have the image Import active and I have deactivated the debug add-on.

    I have just deleted and tried to re-import feed items - and the problem remains - SOME images are not imported.

    Here is an example:

    Original post - has a main featured image:

    http://greenhearttravel.org/teach-abroad-programs/teach-abroad-colombia/travel-for-a-change-and-teach-in-colombia

    Yet once imported, the featured image is gone:

    http://www.greenheart.info/blogs

    Please also note that horrible stretched image - which is caused by not having a minimum image size filter for imported image.

    The end result is not an AUTOBLOG - it's a partially autoblog, which needs continual tweaking and manual moderation.

    Thanks

  • Eugene Manuilov
    • Syntax Hero

    Ok, the example which you have provided doesn't have featured image because the original feed doesn't provide it at all. The original post has featured image, the original feed item doesn't. This is the reason why it has not been imported.

    See attached screenshot of the original feed item. There are no any image tag in the content.

  • Ray Q
    • Site Builder, Child of Zeus

    The two images you highlight are themselves pulled in via AutoBlog from other external blogs - both wordpress.com in this case.

    Should WP be including featured images in the XML feeds by default - if not and what can I do to include this?

    Cheers

  • Eugene Manuilov
    • Syntax Hero

    By default featured images are not included into RSS feed by WordPress. There is a lot of plugins which do the trick. If you can install a plugin on the original site, I would recommend you to find a plugin which adds featured image as media:thumbnail tag. Another option for you is to develop your own small plugin which will do it.

  • Ray Q
    • Site Builder, Child of Zeus

    wow - this is the kind of support I have been waiting FOUR weeks to receive - someone to look at my individual usage of this plugin - how it's installed and how I'm using it and to offer direct suggestions that allow me to fix the issue!!

    Why has this taken 4 weeks to arrive at this point??? sometimes I deeply despair at the support offered on this site...

  • Eugene Manuilov
    • Syntax Hero

    Here is quite simple implementation of the possible plugin which will add featured image to your rss2 feed (not to atom/rdf/etc):

    <?php
    /*
    Plugin Name: Media:Thumbnail
    Plugin URI:
    Description:
    Version: 1.0
    Author: Eugene Manuilov
    Author URI:
    License:
    */
    
    add_action( 'rss2_ns', 'mediathumbnail_rss2_ns' );
    function mediathumbnail_rss2_ns() {
        echo ' xmlns:media="http://search.yahoo.com/mrss" ';
    }
    
    add_action( 'rss2_item', 'mediathumbnail_rss2_item' );
    function mediathumbnail_rss2_item() {
        if ( has_post_thumbnail() ) {
            $image_id = get_post_thumbnail_id();
            if ( $image_id ) {
                $image = wp_get_attachment_image_src( $image_id, 'post-thumbnail' );
                echo '<media:thumbnail url="' . $image[0] . '" width="' . $image[1] . '" height="' . $image[2] . '"/>';
            }
        }
    }

    I haven't tested it but suppose it has to work properly.

  • Ray Q
    • Site Builder, Child of Zeus

    Thanks,

    What is the purpose of the first function? :

    add_action( 'rss2_ns', 'mediathumbnail_rss2_ns' );
    function mediathumbnail_rss2_ns() {
    	echo ' xmlns:media="http://search.yahoo.com/mrss" ';
    }

    --- WPMU is crashing each time I try to post this...?

  • Ray Q
    • Site Builder, Child of Zeus

    three crashes trying to post this ...

    Crashed again - I either get a blue screen or "posting too fast" or a mix of the two.. however - I want to fix my client site before worrying about WPMU problems!

    I've added your plugin and activated it - but I still don't see any change to the feed:

    http://greenhearttravel.org/feed

    I presume this is not caching.. so what is could be blocking this change?

  • Ray Q
    • Site Builder, Child of Zeus

    Ok - this works locally - adding media:thumbnail - but not on the live site.. my local version is a direct copy ( minus a little content ) - same theme and plugins installed and active.. so this is either a cache issue or something on the server..

  • Ray Q
    • Site Builder, Child of Zeus

    Excellent Eugene - thanks for your help here.. I'd like to leave this support request open for a few more days to allow for testing, then I will report back and close the ticket if all is good

    Thanks again!

    Ray

  • Eugene Manuilov
    • Syntax Hero

    Hi @Q Studio

    Just want to let you know that I have published new version of the plugin. Could you please upgrade your plugin and check whether it works for you or not?

    Also could you let me know whether your issue with featured images has been resolved or not? Please, advice.

    Regards,
    Eugene

  • Ray Q
    • Site Builder, Child of Zeus

    Hi Eugene,

    Thanks for following this up.

    After spending 4 weeks trying to fix this issue - the imports now seem to be working correctly - you can check the home page here to see that all posts have images.

    To be honest, I've got no time to upgrade and test or potentially fix issues again right now - but I will make time after next week.

    I'll mark this as resolved for now.

    Thanks

    Ray

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.