$(function() {
	// Highlight current page
	$('#menu a').each(function() {
		if(window.location.pathname == "/") {
			$('#menu ul li:first-child a').addClass('navPage');
			// The above adds it to all submenus as well so take it off
			$('#menu ul ul li:first-child a').removeClass('navPage');
		} else {
			if($(this).attr('href') == window.location.pathname) {
				// Loop through any parents and highlight them
				$(this).parents('#menu li').children('a:first-child').addClass('navPage');
			}
		}
	});
	// Make all columns the same height
	var height = $('#content .col-1').height();
	if($('#content .col-2').height() > height) height = $('#content .col-2').height();
	if($('#content .col-3').height() > height) height = $('#content .col-3').height();
	$('#content .col-1').css({minHeight : height});
	$('#content .col-2').css({minHeight : height});
	$('#content .col-3').css({minHeight : height});
	// Change button on booking form to 'update pricing'
	if($('#vehicle_book .button-quote').length) {
		$('#vehicle_book .button-quote').hide();
		$('#vehicle_book .button-book').attr('src', '/themes/pegasus2011/images/button-update-pricing.png');
	}
});
