// JavaScript Document

//toggle
$(document).ready(function(){ 
    $('.toggler-1').toggleElements( { fxAnimation:'fade', fxSpeed:'fast', className:'toggler1' } ); 
}); 

//googlemaps

function load() {
if (GBrowserIsCompatible()) {
         var icon = new GIcon();
         icon.image = "http://labs.google.com/ridefinder/images/mm_20_red.png";  
         icon.shadow = "http://labs.google.com/ridefinder/images/mm_20_shadow.png";  
         icon.iconSize = new GSize(12, 20);  
         icon.shadowSize = new GSize(22, 20);  
         icon.iconAnchor = new GPoint(6, 20);  
         icon.infoWindowAnchor = new GPoint(5, 1);  
		 var map = new GMap2(document.getElementById("map"));
         map.addControl(new GLargeMapControl());
         var MapTypes = map.getMapTypes();
         MapTypes[0].getName= function() { return "Mapa";}
         MapTypes[1].getName = function() { return "Satelitarna";}
         MapTypes[2].getName = function() { return "Hybrydowa";}
         map.addControl(new GMapTypeControl());
         map.setCenter(new GLatLng(53.70108, 19.96379), 14);
         var info='<div style="background-color: #fff; width: 200px; font-size: 11px; color: #000000"><B>zabart.com</B><hr>Studio / Biuro:<BR>ul. Grunwaldzka 2/14, 14-100 Ostr&#243;da<BR>tel. +48 602 584 801<BR>fax 089 675 20 32</div>';
         var point = new GLatLng(53.697639, 19.964279);
         var marker = new GMarker(point, icon);
         GEvent.addListener(marker, "click", function() {
          marker.openInfoWindowHtml(info);
         });
         map.addOverlay(marker);
         marker.openInfoWindowHtml(info);

}
}

//rss
		function get_rss_feed() {
			//clear the content in the div for the next feed.
			$("#feedContent").empty();
			
			//use the JQuery get to grab the URL from the selected item, put the results in to an argument for parsing in the inline function called when the feed retrieval is complete
			$.get('proxy.php?url='+('http://feeds2.feedburner.com/Interaktywnie?format=xml'), function(d) {
				
				//find each 'item' in the file and parse it
				$(d).find('item').each(function() {
					
					//name the current found item this for this particular loop run
					var $item = $(this);
					// grab the post title
					var title = $item.find('title').text();
					// grab the post's URL
					var link = $item.find('link').text();
					// next, the description
					var description = $item.find('description').text();
					//don't forget the pubdate
					var pubDate = $item.find('pubDate').text();
					
					// now create a var 'html' to store the markup we're using to output the feed to the browser window
					var html = "<div class=\"entry\"><h2 class=\"postTitle\">" + title + "<\/h2>";
					html += "<em class=\"date\">" + pubDate + "</em>";
					html += "<p class=\"description\">" + description + "</p>";
					html += "<a href=\"" + link + "\" target=\"_blank\">Wiecej >><\/a><\/div>";
					
					//put that feed content on the screen!
					$('#feedContent').append($(html));  
				});
			});
			
		};
//
function showtip(){ 
    $('#toolTip').toggle(); 
}; 