jQuery.noConflict();
(function($) {

jQuery(document).ready(function($) {
	
$("div.right_area_banners a").each(function(){
var img = $(this).find("img"),
	img_bg = img.attr("src"),
	ext_index = img_bg.indexOf('.'),
	ext = img_bg.slice(ext_index),
	path = img_bg.slice(0, ext_index),
	name_index = path.lastIndexOf('/');
	name = 'fileadmin/top_arbeitgeber'+path.slice(name_index);
	height = img.attr("height"),
	width = img.attr("width");	
	$(this).css({'background' : 'url(' + name + '_color' + ext + ') no-repeat 0 0', 'width': width, 'height':height, 'display': 'block'});	
	$(this).attr("target", "_blank");
});

$("#skyscraper a").each(function(){
	$(this).attr("target", "_blank");
});

	$("div.right_area_banners a").hover(function() { //On hover...

		//var thumbOver = $(this).find("img").attr("src"); //Get image url and assign it to 'thumbOver'

		//Set a background image(thumbOver) on the <a> tag - Set position to bottom
		//$(this).find("a").css({'background' : 'url(' + thumbOver + ') no-repeat center bottom'});

		//Animate the image to 0 opacity (fade it out)
		$(this).find("img").stop().fadeTo('normal', 0 , function() {
			$(this).hide(); //Hide the image after fade
		});
	} , function() { //on hover out...
		//Fade the image to full opacity 
		$(this).find("img").stop().fadeTo('normal', 1).show();
	});

});

})(jQuery);
