How to Enable LinkedIn company pages in WordPress Jetpack plugin

The Jetpack plugin is installed by default in virtually all WordPress deployments. The plugin, developed by Automattic, provides some extremely useful functions that most bloggers and WordPress site owners want to add to their website. By combining these common functionalities into a single plugin, Automattic saves site owners time by no longer having to scour the internet for compatible, reliable plugins that provide basic functions.

One of these basic functions is the Social Media Icons widget. Adding this widget places common social media icons on a WordPress site, along with links to specific social media profiles. The widget supports Facebook, Twitter, LinkedIn, Google+, Instagram, Pinterest, and several other popular social media platforms.

Unfortunately, this widget was designed to support personal social media profiles and not company profiles. Because LinkedIn uses a slightly different URL structure for company pages, any company pages added to the LinkedIn field in this widget will not work. Below are instructions to remedy this problem. Note that this will involve editing the code of your WordPress theme, so those without previous experience doing so may want to seek help from a more experienced person.

  1. Add the following code to the functions.php file in your themenThis can be accomplished either through the WordPress admin page (Appearance > Editor), or through a text editor on your webhost (such as vim or emacs).
function jetpackme_linkedin_company_icon( $html_array ) {  
return  $html_array + array(
    25 =>    // This key can be modified to change the order the new item will appear in the list
    '<a title="Pitchko Media" '
        . 'href="" '
        . 'class="genericon genericon-linkedin" target="_blank">'
        . '<span class="screen-reader-text">Pitchko Media Company Profile</span></a>'
add_filter( 'jetpack_social_media_icons_widget_array', 'jetpackme_linkedin_company_icon' );
  1. Find your LinkedIn company page URL codenThis is usually the name of your company separated by dashes rather than spaces. For example if your company name is Pitchko Media, the URL code will be pitchko-media.
  2. Insert your LinkedIn company page URL code into the codenIn the example above, replace href="" with href="".
  3. Change the title and screen reader to your company namenAgain, in the example above, replace <a title="Pitchko Media" with <a title="Your Company Name".

    To support screen readers, you should also replace <span class="screen-reader-text">Pitchko Media Company Profile</span> with <span class="screen-reader-text">Your Company Name Company Profile</span> 

  4. Save your changes and refresh your page.

    If you are using the WordPress built-in editor, press Update File. If you are using a text editor, save your file normally (ESC,:wq) for you vim-types.

    Upon refreshing your site, you should see the LinkedIn icon wherever you placed the Social Media Icons widget. Clicking on the icon should take you to your company page.

    This is a quick and dirty method for supporting company pages in the Social Media Icons widget in Jetpack. The original code can be found on the support forum. It would be nice if Automattic built this support into the widget so it can be edited through the widget user interface rather than the code editor. However, since WordPress seems to maintain its focus on individual users and personal blogs, I do not expect to see company/business support any time soon.

Did this work for you? Please leave a comment or send me an email and let me know how you made out. If you need help, please contact me as I would be happy to help you.

One thought on “How to Enable LinkedIn company pages in WordPress Jetpack plugin

Leave a Reply

Your email address will not be published. Required fields are marked *