/*
 * Url preview script 
 * powered by jQuery (http://www.jquery.com)
 * 
 * written by Alen Grakalic (http://cssglobe.com)
 * 
 * for more info visit http://cssglobe.com/post/1695/easiest-tooltip-and-image-preview-using-jquery
 *
 */
 
this.screenshotPreview = function(){	
	
	$("a.screenshot").hover(function(e){
		this.t = this.title;
		this.title = "";	
		var c = (this.t != "") ? "<br/>" + this.t : "";
		$("#outerWrapper").append("<p id='screenshot'><img src='"+ this.rel +"' alt='url preview' />"+ c +"</p>");								 
		$("#screenshot")
			.css("top", "150px")
			.css("left", "50px")
			.css ("position", "absolute")
			.fadeIn("slow");						
    },
	function(){
		this.title = this.t;	
		$("#screenshot").remove();
    });	
	
};


// starting the script on page load
$(document).ready(function(){
	screenshotPreview();
});