Return to Snippet

Revision: 11865
at February 22, 2009 20:19 by lajevardi

Initial Code
function idcRankHandler($args){
	extract(shortcode_atts(array('link' => null),$args));
	$idcRef = !is_null($link) ? "http://idevcenter/link/$link" : "".$hold=rawurlencode(get_permalink($post->ID));
	return '<a href="'.$idcRef .'" class="idcRankAnchor">'
					.'<img src="'.$hold
					.'" title="Vote on" alt="Vote on" class="idcRankImage" />
add_shortcode("idc","idcRankHandler"); //Attaching iDC handler

Initial URL

Initial Description
Shortcode to insert rank in a WP blog post.

Initial Title
iDC WordPress Shortcode

Initial Tags

Initial Language