function location_ready(lat,lon) {
	if (GBrowserIsCompatible()) {
		setTimeout(function() {
			var map = new GMap2(document.getElementById("map-container"));
			map.setCenter(new GLatLng(lat, lon), 16);

			// Controls
			map.addControl(new GSmallMapControl());

			// Create marker icon
			var uscIcon = new GIcon(G_DEFAULT_ICON);
			uscIcon.image = "/_ui/srauscmaster/img/thickbox/pin.png";
			uscIcon.iconSize = new GSize(54, 40);

			// Add marker to map
			var markerOptions = { icon:uscIcon };
			map.addOverlay(new GMarker(map.getCenter(), markerOptions));

			$('#map-container').css('background', 'none');
		}, 500);
    }
}

function form_ready() {
    $('#wrap').append('<div id="wrapCover"></div>');
    $('form').attr('autocomplete','off');
    form_reveal();
}
function form_reveal() {
    /* Check for input ready, otherwise jNice gets applied too early */
    if( $('.component input:text:visible').filter(':last').width() == 0) {
        // continue waiting
    }
    else {
        if( $('#wrap #wrapCover').length > 0 ) {
            $('#asstBody form').jNice();
        }
        $('#wrap #wrapCover').remove();
    }

    // Call itself
    if( $('#wrap #wrapCover').length > 0 ) {
        setTimeout("form_reveal()", 500);
    }
}