in

jetlounge

the minty fresh blog that whitens your teeth!


Syndication


Add Referring Icons to Your Community Server Posts

by David Leibowitz | December 30, 2007 | Comments: 6

I posted a while ago about a neat CS 2007 add-in that automatically adds referrer tags to your posts.

The code is pretty slick, and the author, Christopher Even made the module so you could add as many new referers as you'd lke. By default, in his example he uses text so you'd have:

Technorati | Yahoo! | Google  etc,

I wanted to dress up my posts with a little color and easily identify the referring links with icons instead. That was easy enough, since his module simply does a find and replace on valid HTML code.

In his example he uses:

<a href="http://del.icio.us/post?url=[URL_ENCODED]&tags=[TAGS_ENCODED]&title=[TITLE_ENCODED]" mce_href="http://del.icio.us/post?url=[URL_ENCODED]&tags=[TAGS_ENCODED]&title=[TITLE_ENCODED]">Del.icio.us</a> |

I changed that with the following

1) Change the <a> tag slightly to ensure that the link opens in a new window with target="_blank"

2) Remove the text and add an <img> tag instead:

<img class=link_icon alt="del.ico.us" src="/images/delicious.png" alt="del.ico.us" /></a>

3) Added  some remarks in between links in order to easily find them in the future so the full code is:

<!-- Del.ico.us Tag -->
<a href="http://del.icio.us/post?url=[URL_ENCODED]&tags=[TAGS_ENCODED]&title=[TITLE_ENCODED]" mce_href="http://del.icio.us/post?url=[URL_ENCODED]&tags=[TAGS_ENCODED]&title=[TITLE_ENCODED]" target="_blank">

<img class=link_icon alt="del.ico.us" src="/images/delicious.png" alt="del.ico.us" /></a>

del.ico.us digg this technorati BlinkList Furl reddit DotNetKicks google! live Facebook Stumble Upon Yahoo!



Comments

 

TrackBack said:

February 4, 2008 10:58 PM
 

mystyleit said:

Adding Social Bookmarking to Community Server 2007 Community Server is the platform that powers rich

February 7, 2008 1:09 PM
 

Mike Clarke said:

Hi There,

I found your posts really helpful and implemented Social Booking on my own site.  I also wrote my own guide, check out it!

 

February 7, 2008 1:37 PM
 

Mike Clarke said:

Don't know what went wrong with my first comment.

Anyway, I followed your guide, and created my own!

Thanks,

MC

February 7, 2008 1:38 PM
 

TrackBack said:

March 4, 2008 10:48 AM
 

TrackBack said:

March 4, 2008 10:49 AM

Leave a Comment

(required)  
(optional)
(required)  
Add
Powered by Community Server (Non-Commercial Edition), by Telligent Systems