• Home
  • Articles
    • IT
      • Web Multimedia
      • Oracle
    • Social Media
    • Options
    • Miscellaneous
  • About
  • Contact
Articles Social Media Integration Share on Facebook - Customizing the Text and Images that are posted when your web pages are “Shared” on Facebook

Share on Facebook - Customizing the Text and Images that are posted when your web pages are “Shared” on Facebook

Saturday, 03 April 2010 21:09

Did you know you can customize the text and image that Facebook uses when a visitor to your website uses "Share on Facebook"?

Facebook Post

Facebook Bookmarks or "Share on Facebook"

We have all seen the ubiquitous “Share” buttons on blogs and Corporate websites, such as the below.

Share on Facebook Example Link

They all tend to work the same, when you click Facebook a new browser window opens up and you will see the usual Facebook “Post to Profile” page (such as the one at the top of this article).

What you may or may not know is that the text and image selected by Facebook, and circled in the screenshot above, is completely customizable. You have control over what Facebook displays. Below is what you need to know.

How to Setup a “Share on Facebook” Link or Bookmark

The actual hyperlink for sharing a webpage on Facebook, or put differently, when you post a webpage on your Facebook profile, is really simple. You would just add the following html code to your webpage (it’s just a hyperlink).

<a target="_blank" href="http://www.facebook.com/sharer.php?u= http://garethhooper.com/articles/social-media/45-integration/145-share-on-facebook-controlling-the-text-and-images-that-are-posted-when-you-share-a-webpage-on-facebook.html" title="Share this webpage on Facebook">Share on Facebook</a>

  • This will launch a new browser window, which I highly recommend, rather than lead your visitor away from your website.
  • The u= http://garethhooper.com/articles/social-media/45-integration/145-share-on-facebook-controlling-the-text-and-images-that-are-posted-when-you-share-a-webpage-on-facebook.html is the URL of the page that the "Share on Facebook" link is on. You do have to use the full URL here.
  • The title="Share this webpage on Facebook" is the text that displays when you hover your mouse over the link.
  • The Share on Facebook is the text of the link, otherwise known as the Anchor text.

How to Customize the Text that Facebook uses

In the example above, the title that Facebook chose was "JW Player 5.1 Just Released!". Facebook simply took this from the html title that virtually every webpage has, and for those of you that use Wordpress or Joomla for your Blogs, you may not even realize that Wordpress/Joomla adds the html title for you.

An example of the html title is:

<meta name="title" content="JW Player 5.1 Just Released!" />

In the example at the top of the article, the description that Facebook chose started with "I don't want this text to be the description...". Facebook took this from the meta description that is common on a lot of websites, but as it no longer influences search engine rankings with the big 3 search engines (Google, Yahoo, Bing), it isn't necessarily on EVERY webpage, and if it's not present, Facebook using it's own algorithm to choose a description for you, from text on your webpage. It's this process where a lot of people get those undesirable descriptions, but it doesn't have to be that way. Just specify a meta description of your choosing, like the example below:

<meta name="description" content="This is the description of my webpage that I really want to have shared on Facebook!" />

How to Customize the Image that Facebook uses

In the example at the top of the article, Facebook didn't even display an image, and instead gave the visitor the option of choosing an image that was displayed on the original webpage. This is probably undesirable, and can be customized with an image of your choosing, and that image doesn't even have to be on your website, you can use an image on another website if you wish.


Here's an example of how you can specify the image that Facebook uses, add the following html code to your webpage, ideally in the HEAD section, but if you can't manage that (for example with Wordpress or Joomla where you don't have that much control) it can live in the BODY section.

<link rel="image_src" href="/images/stories/articles/social_media/integration/facebook_post.jpg" />

OR

<link rel="image_src" href="http://garethhooper.com/images/stories/articles/social_media/integration/facebook_post.jpg" />

Example Link

Here's an example link using everything above:

Share on Facebook or

Share_button

Caution when testing your own "Share on Facebook" links

When I was testing all the above information, I noticed that Facebook "appeared" to use some kind of cache. I would update my test page and then test the link and nothing changed. It was only when I changed the title of the page and noticed that Facebook still used the old title, did I suspect that there was some kind of caching going on. Clearing the temporary internet files and using a different browser didn't help, I got the same result. It was only when I tried the link after 30 mins did I see the changes I made reflected on Facebook. It may be much less than 30 mins of cache, I didn't try and time it. Just something to bear in mind.

Related Articles

  • Share on Facebook – How to embed your own Videos on someone's Facebook wall when your web pages are “Shared” on Facebook
  • Share on Facebook – How to embed your own MP3s on someone's Facebook wall when your web pages are “Shared” on Facebook
  • How to create your own Facebook Custom Page with your own page icon
  • Overview of the New Facebook Social Plugins – Part 1 of 3

Please leave me a comment if you found this article useful or if you have any questions.

Share This
Email This

Comments (18)

Subscribe to this comment's feed
...
0
Thanks for the tips Gareth ... I did not know that could be changed!
Shannon , May 24, 2010
  • report abuse
  • +9
  • vote down
  • vote up
...
0
Hi Gareth,
i tried this, but i still get not only the specified image ...
may you haye any idea why?

thanks, wolfram
Wolfram , August 26, 2010
  • report abuse
  • +1
  • vote down
  • vote up
...
0
to get around the caching...i just rename the page each time I test....like index1.htm, index2.htm, etc. When I'm done I give it the right name and it eventually updates.

Thanks for the useful info.
John , December 18, 2010 | url
  • report abuse
  • +3
  • vote down
  • vote up
...
0
Thanks for this. Truly clear and helpful information. It's these little niggling issues that cause me to pull my hair out. Thanks also to commenter Bart for the link to clear the cache. Cheers, John B.
John Bachman , March 26, 2011 | url
  • report abuse
  • +1
  • vote down
  • vote up
...
0
I'd like to know how to replace the text "What's on your mind?" and sometimes "Write something..." with my customized messages.

Tried "&message_text=CUSTOM" appended to the url but no luck. I guess facebook doesn't allow extra parameters passed. :S

Any good tips are greatly appreciated. smilies/smiley.gif
Joy , July 11, 2011
  • report abuse
  • +0
  • vote down
  • vote up
...
0
Friends,
I'm feeling so happy, do u know why? cuz i m so lucky, do u know how? cuz God loves me.Do u know how? cuz he gave me a gift. Do u know what? its YOU my love.
Coolboy , September 10, 2011 | url
  • report abuse
  • -2
  • vote down
  • vote up
...
0
smilies/sad.gifsmilies/shocked.gifsmilies/cool.gifsmilies/kiss.gifsmilies/cry.gifsmilies/tongue.gifsmilies/cheesy.gifsmilies/smiley.gif
sss , October 11, 2011
  • report abuse
  • -1
  • vote down
  • vote up
...
0
Hi guys hope you all are ok! I'm having an issue when I try to share an article to facebook.

The thing is that it loads an article and image that are not in my site (IANA - Sample Domain) and I don't know what to do.

Can you please help me smilies/cry.gif
SoujiroZ , October 19, 2011
  • report abuse
  • +1
  • vote down
  • vote up
...
0
Hi SoujiroZ,

Could you post your website so we can take a look at the code please.

Thanks,

Gareth
Gareth , October 20, 2011 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
Thank you for posting the great content…I was looking for something like this…I found it quiet interesting, hopefully you will keep posting such blogs….Keep sharing
image consultant Melbourne , November 02, 2011 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
This is generally an wonderful writing, wow, it is wonderful,I'm thinking about these right,I have found it extremely useful, looking forward for you as as feasible to update your works! we will in any way instances help you!obd2
Lexia 3 , January 30, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
Can you kindly explain how to setup this process in blogspot blogs. As I am facing problem with my newly setup blog. Whenever me or someone share a post from the site, the description of the post in facebook is displayed as the author bio, which i really hate. I am not able to solve the problem. Kindly help!!!
Sumit Deb , April 20, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
I'm so enjoyable when reading your post. I will recommend it to more people. Thank you for sharing.
coach outlet store , May 05, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
I have to say it is really a good post. I have learnt a lot. Thank you!
Coach Outlet Store Online , May 07, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
You look at and perform web longchamp bag sale page take away the store within your longchamp handbags cheap local urban center.
longchamp le pliage medium , May 14, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
nearly all which in turn Firms Mac Cosmetics wholesale should be warned of just before doing Mac Cosmetics wholesale every choice to visit together with a single corporation over anothernd Foundation Examine if your current weak prospective client continues to be fascinated.
Mac Lipstick Swatches , May 14, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
The actual compare with coloring Tiffany and Co for a sight could make Wholesale Tiffany Jewelry them sound extra remarkable.
Tiffany Necklaces , May 14, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up
...
0
As a jags fan, I agree with you. The Jags haven't had consistant WR since Jimmy Smith and Keenan McCardell. QB's always look better with WR's that can run a route, get open, catch a ball and run with it. There have been glimpse's of light but not enough to continue on the past path. I'm sure Gene Smith stands behind his decisions, but it's not enough. With a new owner willing to bring the Jags into the 21st century it's time for Gene Smith to step up. GO JAGS!rado replica
v , May 15, 2012 | url
  • report abuse
  • +0
  • vote down
  • vote up

Write comment

feedShow/Hide comment form
bold italicize underline strike url image quote smile wink laugh grin angry sad shocked cool tongue kiss cry
smaller | bigger

busy
< Prev

Like us on Facebook

Recommended Articles

  • Site Map
  • Legal
  • Privacy Policy
2011 GarethHooper.com