Open Graph Tags
Facebook introduced Open Graph in 2010. It promotes integration between Facebook and other websites by allowing them to become rich “graph” objects with the same functionality as other Facebook objects.
Put simply, a degree of control is possible over how information travels from a third-party website to Facebook when a page is shared (or liked, etc.). In order to make this possible, information is sent via Open Graph meta tags in the <head> part of the website’s code.
|Specifies title that you would like shared||Optional|
|Specifies type of page that is being shared||Optional|
|Specifies URL that you would like shared||Optional|
|Specifies image/thumbnail that you would like shared||Optional|
|Specifies summary that you would like shared||Optional|
|Specifies site that content is shared from||Optional|
Properties in <Span> Tags
You can specify the URL, title, and image to be shared by adding the following codes into <span> which is stored within the <header>.
|Specifies URL (can be shortened URL) that you would like shared|
|Specifies title that you would like shared|
|Specifies link to image you would like displayed in the shared content|
|Specifies summary text/description you wish to share|
Example This button is set to share the ShareThis home page with the title “Sharing is great!”
You can modify the
|Specifies the social destination to share to||Required|
|Specifies which sharing button on page. Usually this is the id of span id of the HTML element containing the button||Required|
|Specifies URL that you would like shared||Required|
|Specifies title string that is shared||Required|
|Specifies the type of button to display. Default is ||Required|
|Specifies optional text to be displayed next to the ShareThis button on your page||Optional|
|Specifies link to the image to be shared||Optional|
|Specifies summary text to be shared||Optional|
This example creates a button that connects to a large format ShareThis button and shares the ShareThis home page with a description. It shares a custom image.
Order of Precedence
It is important to remember the order of precedence by which the ShareThis code processes share properties. Generally, we recommend using one approach by which sharing properties are specified on your pages to prevent errors.
- Properties specified in tags i.e. second precedence
- Open Graph Protocol tags i.e. lowest precedence