Social Media Buttons

One feature of the PDF to HTML5 converter that is useful for those publishing their converted content online is the inclusion of social media buttons.

Currently the converter supports the following social media sites:

  • Facebook
  • Twitter
  • LinkedIn
  • Google+
  • Reddit
  • Dig
  • StumbleUpon
  • Tumblr

Each button will share a link to the current page you are viewing to the chosen button’s social networking site.

How to add them to your HTML files

The appearence (or lack therof) of these Share buttons is controlled by the flag:

org.jpedal.pdf2html.socialMediaLinks

Turning them all on results in something like this:

socialMediaButtons resized 600

To do this simply set the previously mentioned flag to equal “all”:

org.jpedal.pdf2html.socialMediaLinks="all"

Controlling which buttons are present

You can control those that specfically appear using the same flag. For instance, if you only want to display the Twitter Tweet button you would set the flag equal to “twitter”:

org.jpedal.pdf2html.socialMediaLinks="twitter"

justTwitter


Or if you only wanted to show the Facebook Like button you would set it to “facebook”:

org.jpedal.pdf2html.socialMediaLinks="facebook"

onlyLike resized 600


You can also enable multiple buttons as you want them by separating each one you want using a comma:

org.jpedal.pdf2html.socialMediaLinks="twitter,facebook"

faceBookAndTwitter resized 600

Supported Values

The current supported values are:

Social Network/Media Site Value
Facebook facebook
Twitter twitter
Google+ googleplus
LinkedIn linkedin
Reddit reddit
Dig dig
StumbleUpon stumbleupon
Tumblr tumblr
All of the above all
None of the above none

Currently if you do not use this flag the default behaviour is not to include any social media buttons.

Note: Most of these social media buttons will not work unless the page is hosted online.