// 2010.02.14 - For ESC Law
// Grendelfly - A Division of SC&G Technology Solutions
//
// Requires JQuery: jquery-1.3.2.min.js or above



$(function(){
$(document).ready(function() {

// Navigation Functions

	// Replace Nav w/ Spacer Images Function
	$('a.repl').each(function(){
		$(this).html('<img src="/img/spacer.gif" width="157" height="19" />');
	});


// Replace Tags w/Images

	// H1 title tag and file name of image should be the same
	// Img spaces in file name should be replaced with "_"
	// Img file name should start with "tx_"
	$('.repl').each(function(){					   
		var r_img = this.title;
		if(r_img !=""){
			r_img = r_img.toLowerCase();
			r_img = r_img.replace(/ /gi,"_");
		$(this).html('<img src="/img/tx_'+ r_img +'.gif" />');
		$('.repl img').css({'border':'none'});
		}; // if(r_img !="")
	});

// Image Mouse Over Effect

	$('.m_ovr').hover(function(){
		var g_src = $(this).attr('src');
		var r_src = g_src.replace("/img/","").replace(".gif","");
		$(this).attr({'src':'/img/'+ r_src +'_ovr.gif'});
	},function(){
		var g_src = $(this).attr('src');
		var r_src = g_src.replace("/img/","").replace("_ovr.gif","");
		$(this).attr({'src':'/img/'+ r_src +'.gif'});
	});


}); // $(document).ready(function()
}); // $(function()

