

$(document).ready(function()
{  
	//$('.input_mittel').removeAttr('size');
	//$('.input_mittel').removeAttr('multiple');
	
	
	//$('.input_mittel').addClass('input_klein');
	//$('.input_mittel').removeClass('input_mittel');
	
	$('.list_table').css('width','100%');
	
	$('#list_head th, #list_head td').each(function(){
		
		$(this).css('height','28px');
		$(this).html($(this).html().replace(/(<([^>]+)>)/ig,""));
	});
	
	
	
	
	$('img').each( function(){
		if( $(this).attr('src')=='_img/bullet_w.gif' || 
		($(this).attr('src')=='_img/bullet_tr.gif' &&
		$(this).next().length>0 &&
		$(this).next().get(0).tagName
		))
		{
			 $(this).css('margin-right','5px');
		}
		});
		
		var p = '';
		$('a[href*="&p="]').each( function(){
			p = "_p";
		});
			
		$('<div id="numbers'+p+'" style="float:right;"></div>').insertAfter('.list_table');
		
		var par = null;
		$('a[href*="&sta"], a[href*="&p="]').each( function(){
				par = $(this).parent();
			});
			
		
		$('a[href*="&sta"], a[href*="&p="]').appendTo('#numbers'+p);
		
		if(par != null)
		{
			par.html('');
		}
		$('a[href*="&sta"], a[href*="&p="]').each( function(){
	 	
		$(this).parent().attr('nowrap','nowrap');
		$(this).attr('style','width:20px;height:20px;background-color:#abadae;display:block;text-align:center;line-height:20px;vertical-align:center;margin-right:2px;color:#fff;float:left;');
		
		$(this).mouseover(function(){
			$(this).attr('style',$(this).attr('style')+";color:#fff !important;background-color:#ff9000;");
		});
		$(this).mouseout(function(){$(this).css('background-color','#abadae')});
		
		if($(this).html()=='Weiter')
		{
			$(this).html('>');
		}
		else if($(this).html()=='Zurück')
		{
		 	$(this).html('<');
		}
		else
		{
			if($(this).html().indexOf('[')>-1)
			{
				$(this).addClass('numberSelected');
				var htm = $(this).html();
				htm = htm.replace(/\[/i, "");
				htm = htm.replace(/\]/i, "");
				$(this).html(htm);
			}
			else
			{
			//	$(this).html('<img src="/_img/box_bullet.gif">');
			}
		}
		
		});
		
		$('.list_table td').removeAttr('nowrap');
		
		
	/* HTML TAGS FOR REPLACEMENT */
	Cufon.replace('h1',{fontFamily:'Helvetica Bold', hover:true });
	Cufon.replace('.button',{fontFamily:'Helvetica Bold', hover:true });
	
});
