			$('a[id^="marker"]').each(function() {
				var id = $(this).attr('id').replace('marker', '');
				if( $('#buble' + id).attr('id') != null )
				{
					$(this).click(function() {
						if( $('#buble' + id).css('display') == 'none' )
						{
							$('#buble' + id).fadeIn(500);
						}
						else
						{
							$('#buble' + id).fadeOut(500);
						}
					});	
				}
				else if( $(this).attr('href') != '#' )
				{
					$(this).click(function() {
						$('#innerwrap').load($(this).attr('href'));
						$("#gallery").fadeIn(1000);
						$("#innerwrap").fadeIn(1000);
						return false;
					});
				}
				else
				{
				}
			});
			$('a[id^="gmarker"]').each(function() {
				$(this).click(function() {
					$("#innerwrap2").load($(this).attr('href'));
					$("#gallery2").fadeIn(500);
					$("#innerwrap2").fadeIn(500);
					return false;
				});
			});	

			$('#viewport').scroll(function() {
				$('.buble').each(function() {
					if( $(this).css('display') == 'block' )
					{
						var id = $(this).attr('id').replace('buble', '');
						$('#marker'+id).click();					
					}
				});
			});

