﻿//设置当前连接样式
function setCurrentStyle(o,classid){
	var o=$(o)
	if(o.length)
	{
		o.each(function(){
			if((new RegExp($(this).attr("href").replace(/(?=[.?\\|])/ig,"\\")+"$","i")).test(window.location.href) || (classid>0 && $(this).attr("href").split("=")[1]==classid))
			{
				$(this).addClass("current");
				$(this).parent().addClass("current");
			}
		});
	}
}

