Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • xumbrella Friend
    #194692

    Hi I just noticed when you post a comment it does not post the image thumb to the facebook timeline, any idea why this might be?

    see attached screen shots, one of the comment on the post, and one of the entry on the commenters timeline..

    thanks


    1. Screen-Shot-2014-02-11-at-14.56.22
    2. Screen-Shot-2014-02-11-at-14.57.38
    Wall Crasher Developer
    #522509

    Hi xumbrella,

    Please enable JA Lazyload plugin and try to edit pluginssystemjalazyloadjalazyload.php

    replace

    JResponse::setBody($body);

    to

    if(JRequest::getCmd('option') == 'com_content' && JRequest::getVar('view') == 'article' && JRequest::getInt('id')){

    $db = JFactory::getDbo();
    $query = $db->getQuery(true);
    $query->select('images');
    $query->from('#__content');
    $query->where('id = ' . JRequest::getInt('id'));
    $db->setQuery($query);

    $images = $db->loadResult();

    if($images && strlen($images) > 0){
    $images = json_decode($images);

    if($images && $images->image_intro){
    $body = str_replace ('</head>', '<meta property="og:image" content="' . $images->image_intro . '" />' . "n" . '</head>', $body);
    }
    }
    }

    JResponse::setBody($body);

    Please pm ftp/admin information to me so I can check it on your site.

    Regards

    xumbrella Friend
    #522880

    Hi, I updated the code and cleared both browser cache and joomla cache but it still does not post the image… I also notice that using IFTTT that it is unable to post images, is that to the same fault?

    I will PM you the admin.. please let me know if you can work out why this does not work correctly.

    thanks

    Wall Crasher Developer
    #522981

    @ xumbrella,

    I have updated the file on your site. Please clear the system cache and try again.
    You may need to wait for some days for Facebook to refresh their cache too.

    I just replaced:

    $body = str_replace ('</head>', '<meta property="og:image" content="' . $images->image_intro . '" />' . "n" . '</head>', $body);

    with:

    $body = str_replace ('</head>', '<meta property="og:image" content="' . JUri::base() . $images->image_intro . '" />' . "n" . '</head>', $body);

    Hope it helps.

    xumbrella Friend
    #523376

    Hi Thanks for the help, however, I cleared the cash and made a comment but the post to facebook still shoes no image… see attached screen grab… should I need to wait for facebook to refresh on new posts too?


    1. Screen-Shot-2014-02-19-at-08.45.06
    Wall Crasher Developer
    #523552

    @ xumbrella,

    It seems you select not to get cache the youtube image in the past.
    Those article which you make a test seems old.

    I just make change:

    if($images && $images->image_intro){
    $body = str_replace ('</head>', '<meta property="og:image" content="' . JUri::base() . $images->image_intro . '" />' . "n" . '</head>', $body);
    }

    to

    if($images && $images->image_intro){
    if(!(strpos($images->image_intro, 'http') === 0 || strpos($images->image_intro, '//') === 0)){
    $images->image_intro = JUri::base() . $images->image_intro;
    }

    $body = str_replace('</head>', '<meta property="og:image" content="' . $images->image_intro . '" />' . "n" . '</head>', $body);
    }

    You can use this tool to check if the image working.
    https://developers.facebook.com/tools/debug/

    http://www.clipular.com/c/4891041362608128.png?k=zIlBNByRM4K_rdsaJi0zDzaNDuI

    The facebook cache can be 24 hours.
    http://stackoverflow.com/questions/5776567/facebook-open-graph-not-clearing-cache

    Please check again.

    xumbrella Friend
    #523784

    Hi there, many thanks for your help, it works now.

    Can you please explain more what changes you made? I don’t quite understand from your explanation…

    thanks again.

    Wall Crasher Developer
    #523980

    @ xumbrella,

    As your article is video, there was no image to show.
    I just tried to make the image of video available to open graph protocol. Facebook will crawl that data and display.

Viewing 8 posts - 1 through 8 (of 8 total)

This topic contains 8 replies, has 2 voices, and was last updated by  Wall Crasher 10 years, 9 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum