User avatar as post image in LinkedIn

One of my coworkers posted a blog in our community and wanted to share the blog post with his LinkedIn network. When he embedded it in LinkedIn, the auto-generated image was his user avatar:

The blog post has 2 gifs (but no .png/.jpg images) and I also added one of the gifs as the Post Image in the Blog Options. Is this expected behavior? Is there a way to specify a different image from the Telligent side? 

Parents Reply Children
  • Hi Alex, you can look at core_v2_page.AddOpenGraphMetaTag for adding an "og:image" meta tag. You could specify it to fall back to the group avatar or site logo, for instance, if there was no image associated with the post.

  • Thanks,  . That helped to give some more info. I was curious as I found a widget, SEO Meta Data for Content Pages, which appears to have a field to define that og:image meta tag you mentioned. I tried adding it on the Forum Thread page and to the group's header (and locking it) as this group only has one application (that forum). Uploading an image and publishing the theme didn't appear to help. 

    I then tried to (in our staging site) create a duplicate of that widget in Widget Studio, removed most of the Content options, and edited line 2 from  #set($page = $core_v2_customPage.Current) to   #set($page = $core_v2_page.Current) :

          #set($page = false)
          #set($page = $core_v2_page.Current)
    
          #if (!$page)
          $core_v2_widget.Hide()
          #end
    
          #set($ogImage =  $core_v2_widget.GetUrlValue("openGraphImage",""))
          #if($ogImage != "")
          $core_v2_page.AddOpenGraphMetaTag("og:image",$core_v2_encoding.HtmlAttributeEncode($core_v2_page.AbsoluteUrl($ogImage)))
          #end

    I also removed all of the configuration settings, other than to control the image:

          <propertyGroup id="openGraph" resourceName="OpenGraph">
            <property id="openGraphImage" dataType="url" defaultValue="" resourceName="OpenGraphImage" descriptionResourceName="OpenGraphImage_Description"  controlType="Telligent.Evolution.Controls.ThemeFileUrlControl, Telligent.Evolution.Platform">
              <propertyRule type="Telligent.Evolution.Controls.PropertyRules.FileExtensionRule, Telligent.Evolution.Platform" validExtensions="gif,jpg,jpeg,png" />
            </property>
    
          </propertyGroup>

    I re-tested with the same basic steps as above, but using the link Ben shared, https://www.linkedin.com/post-inspector/inspect, I wasn't getting any changes. 

    Am I overcomplicating this? Can I just add an Unfiltered HTML widget to the header and put in something like:

    core_v2_page.AddOpenGraphMetaTag(og:image, {url_of_image});

    Any ideas? Thank you!

  • I'll leave my above reply in case there is something that can be built on or if it helps anyone in the future, but I made some progress on this specific issue with the help of  's reply here (thanks Kevin!):  RE: Global "no index no follow"? . I used the package that Kevin created and changed the content to core_v2_page.AddOpenGraphMetaTag("og:image", "{my image file}");

    I deployed the widget on the Forum Thread page for this group and the image now shows properly. I need to make some changes to the actual image file that's being used, but it's a huge improvement over the pixelated avatar that was there before. 

  • The "SEO for Content Pages" widget is for custom content pages, since they do not have any actual content object to base their header generation off of Standard pages for content generate those headers based on data supplied from the content itself. And yes, the core_v2_page.AddOpenGraphMetaTag method is the supported way to change those values from the widget.