/***********************
*  Site Specific JS   *
************************/

// Custom JavaScript Document

$(document).ready(function(){  
  $('head').append('<link rel="shortcut icon" type="image/x-icon" href="http://cdn.myld.com.au/2/347/pool-spa-doctor_bc793feffc.ico">');
  $('#logo').html('<a href="/"><img src="http://cdn.myld.com.au/2/347/pool-spa-doctor_1d1c0fc9de.png" alt="Pool &amp; Spa Doctor" /></a>').appendTo('.logo-here');
  $('.navbar').appendTo('.nav-here');
  $('#header').prependTo('body');
  if($('body#home').is('*')) {
   $('.other-page-slider').remove();
    $('#slideshow').bjqs({
            randomstart : true,
            width : 1650,
            height : 717,
            centercontrols : false,
            showmarkers : false,
            responsive : true,
            usecaptions : true
        });
  } else {
    $('#header').after($('#slider'));
     $('#slideshow').bjqs({
            randomstart : true,
            width : 1200,
           height : 333,
            centercontrols : false,
            showmarkers : false,
            responsive : true,
            usecaptions : true
        });
  }
  
  $("#page-not-found div#error").wrap("<div class='container'>").wrap("<div class='row-fluid'>").wrap("<div class='span12'>");

  //********Windows IE8 and below popup*********//   		     		
	$("body").browserDetect( {     	
		name: "Pool & Spa Doctor",     
		logo: "http://cdn.myld.com.au/2/347/pool-spa-doctor_1d1c0fc9de.png",      
		phone: "+08 8952 2405",     //optional
		fax: "+08 8952 2997",      //optional
		email: "poolandspa@bigpond.com",      //optional
		address: "3/2 Ghan Rd Alice Springs NT 0870",  //optional	
		ldprofile: "http://www.localdirectories.com.au/Alice-Springs-Area,NT/Pool-Spa-Doctor/profile/8ZBJ"  
	});  

	//********Mobile Telephone*********//  
	mobileTel(0889522405); //edit phone number
	
	$(".gradient").prepend("<div class='gradient-shadow' />");
	$(".contentHomeBox").prepend("<div class='gradient-shadow' />");
	$("#mainContent").prepend("<div class='gradient-shadow' />");

});

  $(document).ready(function(){ 
    $('#custom_form').formValidation({ 
        validateText: ["name"],
        validateEmail: ["email"],
        validateSpam: true
    });


      $('#footer-map, #map-canvas').gmap3({
  		 marker:{
				 address: "3/2 Ghan Rd Alice Springs NT 0870" //place Your address here
			 },
			 map:{
				 options:{
					 zoom: 15
				 }
			 }
		 });
  });
 