Store Locator

"); giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, function(returnVal){ var Timing ="

No store timing available..

"; if(returnVal.length > 0){ Timing ="
"+ ""+ ""+ ""+ ""+ ""+ ""; for (var i = 0; i "+ ""+ ""+ ""+ ""; } Timing += "
DaysFromTo
"+ weekDays[returnVal[i]["store_meta_key"]]+""+ fromTime +""+ toTime +"
"+ "
"; jQuery('.sloc_timing_container').html(Timing); }else{ jQuery('.sloc_timing_container').html(Timing); } }, "dd.", false); }}); }); /****************** Open Timing Details **************/ jQuery('.sl_loadAddDetails').live('click', function(e){ e.preventDefault(); jQuery('.sloc_more_info_container').empty(); var StoreId = jQuery(this).attr('data-id'); jQuery("#sl_more_info").lightbox_me({centered: true, onLoad: function() { var sl_frontsearch_dal = { action: 'sl_dal_searchlocation', funMethod: 'LoadMoreInfo', LocationId : StoreId }; jQuery('.sloc_more_info_container').html("
"); giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, function(returnVal){ var moreInfo ="

No store info available..

"; if(returnVal.length > 0){ moreInfo ="
"; for (var i = 0; i "+ "
"+ "
"+ "
"; } moreInfo += "
"; jQuery('.sloc_more_info_container').html(moreInfo); }else{ jQuery('.sloc_more_info_container').html(moreInfo); } }, "dd.", false); }}); }); /**************** go back to search panel ***********/ jQuery('.gobackO').live('click', function(e){ e.preventDefault(); jQuery('#sl_new_searchResult,.dirTitle').empty(); jQuery('#sloc_frmSearch').show(); jQuery('.dirTitle').hide(); if(searchMode == 'SM'){ jQuery('#sl_new_searchResult').append(""); jQuery('.DHead').remove(); var RadType = jQuery.trim(jQuery('#sloc_hdfORadTy').val()); if(RadType =="Kms"){ jQuery('input[name=radius]:eq(0)').attr('checked', 'checked'); }else{ jQuery('input[name=radius]:eq(1)').attr('checked', 'checked'); } RadType = (RadType == 'Kms') ? 'Kms' : 'Miles'; var radian = jQuery('#sloc_hdfORad').val(); var catId = 0; jQuery('#sloc_selRadius').val(jQuery('#sloc_hdfORad').val()); if(jQuery('#sloc_selCategory').length > 0){ jQuery('#sloc_selCategory').val(jQuery('#sloc_hdfOCatId').val()); catId = jQuery('#sloc_hdfOCatId').val(); } radian = (RadType === 'Miles') ? Math.round(radian*1.609) : radian; jQuery('#sloc_tbPlace').val(jQuery('#sloc_hdfAddress').val()); if(jQuery('#sloc_hdfOLat').val().length > 0){ SearchStore(jQuery('#sloc_hdfOLat').val(), jQuery('#sloc_hdfOLng').val(), radian, RadType, catId); }else{ SearchStore(jQuery(this).attr('lat'), jQuery(this).attr('lng'), 0, "KM", catId); } jQuery('#sl_nearStore').removeAttr('disabled'); } else if(searchMode == 'BM'){ jQuery('#sloc_frmSearch').show(); jQuery('.sloc_catDrop').show(); var CateId = 0; if(jQuery('#sloc_selCategory').length > 0){ CateId = jQuery('#sloc_hdfOCatId').val(); jQuery('#sloc_selCategory').val(jQuery('#sloc_hdfOCatId').val()); } else{ CateId = 0; } LoadBrowse("All", ''); jQuery('.Lappend').append(""); var sl_frontsearch_dal = { action: 'sl_dal_searchlocation', funMethod: 'BrowseList', SelectMet: 'country', selVal: '', CateId: CateId, Country_name : '' }; giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, BindCountryList, "dd.", false); } }); jQuery('.BM #sloc_selCategory').bind('change', function(){ jQuery('#sl_new_searchResult,.dirTitle').empty(); jQuery('.Lappend').append(""); LoadBrowse("All", ''); var sl_frontsearch_dal = { action: 'sl_dal_searchlocation', funMethod: 'BrowseList', SelectMet: 'country', selVal: '', CateId: jQuery('#sloc_selCategory').val(), Country_name : '' }; giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, BindCountryList, "dd.", false); }); /*************** load country list for browse mode **************/ function BindCountryList(returnVal){ if(returnVal!=null){ if(returnVal.length > 0){ var content = ""; jQuery('#sl_new_searchResult').append(content); for (var i = 0; i  "+ returnVal[i]["country"] +""; jQuery('ul.sloc_browse').append(content_htm); } setTimeout(function(){ jQuery('.Loader').fadeOut('slow').remove(); },200); } else{ jQuery('#sl_new_searchResult').append('
No stores found.
'); setTimeout(function(){ jQuery('.Loader').fadeOut('slow').remove(); },200); } } else{ jQuery('#sl_new_searchResult').append('
No stores found.
'); setTimeout(function(){ jQuery('.Loader').fadeOut('slow').remove(); },200); } } /************* load state list for corresponding country **********/ jQuery('.sloc_browse li a.naadu').live('click', function(){ if(!jQuery(this).hasClass('ajax_req')){ jQuery(this).addClass('ajax_req'); var type = jQuery(this).attr('type'); var resVal = jQuery(this).attr('rel'); var country_name = resVal; jQuery('.sloc_browse li').removeClass('selected'); jQuery(this).parent("li").addClass('selected'); jQuery('.sloc_browse li a').removeClass('selectb'); jQuery(this).addClass('selectb'); jQuery('.Lappend').append(""); LoadBrowse(type, resVal); jQuery('ul.state').fadeOut(400, function(){ jQuery(this).remove(); }); var CateId = 0; if(jQuery('#sloc_selCategory').length > 0){ CateId = jQuery('#sloc_selCategory').val(); jQuery('#sloc_hdfOCatId').val(CateId); } else{ CateId = 0; jQuery('#sloc_hdfOCatId').val(0); } var sl_frontsearch_dal = { action: 'sl_dal_searchlocation', funMethod: 'BrowseList', SelectMet: type, selVal: resVal, CateId: CateId, Country_name : country_name }; giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, BindList, "dd.", false); } }); function BindList(returnVal){ if(returnVal!=null){ var content = ""; jQuery('.sloc_browse li.selected').append(content); for (var i = 0; i  "+returnVal[i]['state']+""; jQuery('ul.state').append(content_htm); } setTimeout(function(){ jQuery('.Loader').fadeOut('slow').remove(); },200); jQuery('.sloc_browse li a.naadu').removeClass('ajax_req'); }else{ jQuery('.sloc_browse li a.naadu').removeClass('ajax_req'); } } /************* load address list for corresponding city **********/ jQuery('.city li a.nagaram').live('click', function(){ if(!jQuery(this).hasClass('ajax_req')){ var $thisEle = jQuery(this); jQuery(this).addClass('ajax_req'); var type = jQuery(this).attr('type'); var resVal = jQuery(this).attr('rel'); var country_name = jQuery('.sloc_browse li.selected a').attr('rel'); jQuery('.city li').removeClass('selected'); jQuery(this).parent("li").addClass('selected'); jQuery('.city li a').removeClass('selectc'); jQuery(this).addClass('selectc'); jQuery('.Lappend').append(""); jQuery('ul.storelist').fadeOut(400, function(){ jQuery(this).remove(); }); LoadBrowse(type, resVal); setTimeout(function(){ jQuery('.Loader').fadeOut('slow').remove(); $thisEle.removeClass('ajax_req'); },200); } }); /************* load city list for corresponding state **********/ jQuery('.state li a.maanelam').live('click', function(){ if(!jQuery(this).hasClass('ajax_req')){ jQuery(this).addClass('ajax_req'); var type = jQuery(this).attr('type'); var resVal = jQuery(this).attr('rel'); var country_name = jQuery('.sloc_browse li.selected a').attr('rel'); jQuery('.state li').removeClass('selected'); jQuery(this).parent("li").addClass('selected'); jQuery('.state li a').removeClass('selects'); jQuery(this).addClass('selects'); jQuery('.Lappend').append(""); LoadBrowse(type, resVal); jQuery('ul.city').fadeOut(400, function(){ jQuery(this).remove(); }); var CateId = 0; if(jQuery('#sloc_selCategory').length > 0){ CateId = jQuery('#sloc_selCategory').val(); jQuery('#sloc_hdfOCatId').val(CateId); } else{ CateId = 0; jQuery('#sloc_hdfOCatId').val(0); } var sl_frontsearch_dal = { action: 'sl_dal_searchlocation', funMethod: 'BrowseList', SelectMet: type, selVal: resVal, CateId: CateId, Country_name : country_name }; giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, BindCtyList, "dd.", false); } }); function BindCtyList(returnVal){ if(returnVal!=null){ var content = ""; jQuery('.state li.selected').append(content); for (var i = 0; i "+returnVal[i]['city']+""; jQuery('ul.city').append(content_htm); } setTimeout(function(){ jQuery('.Loader').fadeOut('slow').remove(); },200); jQuery('.state li a.maanelam').removeClass('ajax_req'); }else{ jQuery('.state li a.maanelam').removeClass('ajax_req'); } } /*** Load All Locations***/ function LoadAllLocation(){ var type = "All"; var selValue = ''; var CatId = 0; var mapOptions; fullSiteWidth = jQuery('.giz_storeLocator').width(); if(fullSiteWidth >= 320 && fullSiteWidth 650){ mapOptions ={ zoom: 10, mapTypeId: google.maps.MapTypeId.ROADMAP, zoomControl: true, scaleControl: true, zoomControlOptions: { style: google.maps.ZoomControlStyle.LARGE, position: google.maps.ControlPosition.RIGHT_TOP }, panControl: true, panControlOptions: { position: google.maps.ControlPosition.RIGHT_TOP }, streetViewControl: true }; }else{ mapOptions ={ zoom: 10, mapTypeId: google.maps.MapTypeId.ROADMAP, zoomControl: false, scaleControl: true, zoomControlOptions: { style: google.maps.ZoomControlStyle.LARGE, position: google.maps.ControlPosition.RIGHT_TOP }, panControl: false, panControlOptions: { position: google.maps.ControlPosition.RIGHT_TOP }, streetViewControl: false }; } var map = gMap = new google.maps.Map(document.getElementById("sl_front_map_canvas"), mapOptions); var bounds = new google.maps.LatLngBounds(); var infoWindow = new google.maps.InfoWindow; var arrayData = []; var sl_frontsearch_dal = { action: 'sl_dal_searchlocation', funMethod: 'LoadMapAndSet', Location: type, selValue: selValue, CateId: CatId, Country_name: '' }; giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, function(markers){ if(markers != null){ if( markers.length 0){ iconImg = plugin_path + iconImg; markImage = new google.maps.MarkerImage(iconImg); } else{ iconImg = "http://www.google.com/intl/en_us/mapfiles/ms/micons/red-dot.png"; markImage = new google.maps.MarkerImage(iconImg); } } var marker = new google.maps.Marker({ map: map, position: point, icon: iconImg, animation: google.maps.Animation.DROP }); bounds.extend(point); var htmPhone =''; var htmFax =''; var htmEmail =''; var htmWeb =''; var htmLogo =''; var phone_fax =''; var htmLabel = ''; var htmlTiming = ''; var htmlDetails = ''; var add_width = (jQuery('#sloc_leftBar').width()-105) + 'px'; var Total_str = "Osoite :" + address; htmPhone = (Phone.length > 0) ? '
'+ Phone +', ' : '
'; if(Phone.length > 0) { Total_str = Total_str + ',Phone: ' + Phone; } htmFax = (fax.length > 0) ? ''+ fax +'
' : '
'; if(fax.length > 0) { Total_str = Total_str + ',Fax : ' + fax; } if(email.length > 0){htmEmail = ''; Total_str = Total_str + ',Email : ' + email;} if(web.length > 0){htmWeb = '
: '+ web +'
'; Total_str = Total_str + ',Website : ' + web;} if(logo.length > 0){htmLogo = '';} else{htmLogo = '';} htmLogo = ''; add_width = '99%'; phone_fax = htmPhone + htmFax; var path = window.location.protocol + "//" + window.location.host + '/products/StoreLocator/'; var orgin = window.location.protocol + "//" + window.location.host; var likeUrl = encodeURIComponent( main_path +'?Location=Social&StoreLocation='+ markers[i]["lat"] +"~"+ storeId + "~" + markers[i]["lng"]); var likeUrlN = main_path +'?Location=Social&StoreLocation='+ markers[i]["lat"] +"~"+ storeId + "~" + markers[i]["lng"]; var imageUrl = encodeURIComponent('http://maps.googleapis.com/maps/api/staticmap?center='+markers[i]["lat"]+','+markers[i]["lng"]+'&markers=color:red|'+markers[i]["lat"]+','+markers[i]["lng"]+'&zoom=15&size=851x315&sensor=false'); var imageUrlN = 'http://maps.googleapis.com/maps/api/staticmap?center='+markers[i]["lat"]+','+markers[i]["lng"]+'&markers=color:red|'+markers[i]["lat"]+','+markers[i]["lng"]+'&zoom=15&size=851x315&sensor=false'; var imageUrlFb = encodeURIComponent('http://maps.googleapis.com/maps/api/staticmap?center='+markers[i]["lat"]+','+markers[i]["lng"]+'&markers=color:red|'+markers[i]["lat"]+','+markers[i]["lng"]+'&zoom=10&size=150x150&sensor=false'); var fb ='
'; var pinit='
'; var tweet='
'; fb = (markers[i]["facebook"] === "1") ? fb : ""; pinit = (markers[i]["printrest"] === "1") ? pinit : ""; tweet = (markers[i]["twitter"] === "1") ? tweet : ""; var Social =''; var toolCss = ""; if(fb.length > 0 || pinit.length > 0 || tweet.length > 0){ toolCss = ""; }else{ toolCss = "no"; } var directionLink = (getDirections == "Popup") ? "javascript:void(0);" : "http://maps.google.com/maps?f=d&z=13&daddr="+ markers[i]["lat"] + ","+ markers[i]["lng"]; var directionsCss = (getDirections == "Popup") ? "sl_GetDirection" : "sl_GetDirection_1"; var directionTarget = (getDirections == "Popup") ? "" : "target='_blank'"; var directionhtm = 'Get Directions'; htmlTiming = (isStoreTime == 1) ? 'Load Store Timing' : ""; htmlDetails = (isAddiDetails == 1) ? 'More Info' : ""; if(labelId > 1){ htmLabel = '
'+ labelText +'
'; } var html1 = '
'+ name +'
'+ htmLogo +'
'+ '
'+ address +'
'+ phone_fax + htmEmail + htmWeb + '
'+ directionhtm + htmlTiming + htmlDetails +'
'; bindInfoWindowN(marker, map, infoWindow, html1, i, false ); htmPhone =''; htmFax =''; htmEmail =''; htmWeb =''; htmLogo =''; arrayData.push(Social); if(directionhtm.length > 1){ jQuery("a.sl_gall").each(function(i){ jQuery(this).simpletip({ fixed: true, content: jQuery(this).find('img').attr('alt') }); }); } } setTimeout(function() { UpdateSearchPnl(); },1000); setTimeout(function() { if( markers.length > zoomBound){ map.fitBounds(bounds); }else{ map.setCenter(marker.getPosition()); } }, 1500); } } }); } /*** Load Browse Type Data***/ function LoadBrowse(type, selValue){ if(type =="City"){ var content = ""; jQuery('ul.city li.selected').append(content); } var CatId = 0; if(jQuery('#sloc_selCategory').length > 0){ CatId = jQuery('#sloc_selCategory').val(); jQuery('#sloc_hdfOCatId').val(CatId); } else{ CatId = 0; jQuery('#sloc_hdfOCatId').val(0); } var mapOptions; fullSiteWidth = jQuery('.giz_storeLocator').width(); if(fullSiteWidth >= 320 && fullSiteWidth 650){ mapOptions ={ zoom: 10, mapTypeId: google.maps.MapTypeId.ROADMAP, zoomControl: true, scaleControl: true, zoomControlOptions: { style: google.maps.ZoomControlStyle.LARGE, position: google.maps.ControlPosition.RIGHT_TOP }, panControl: true, panControlOptions: { position: google.maps.ControlPosition.RIGHT_TOP }, streetViewControl: true }; }else{ mapOptions ={ zoom: 10, mapTypeId: google.maps.MapTypeId.ROADMAP, zoomControl: false, scaleControl: true, zoomControlOptions: { style: google.maps.ZoomControlStyle.LARGE, position: google.maps.ControlPosition.RIGHT_TOP }, panControl: false, panControlOptions: { position: google.maps.ControlPosition.RIGHT_TOP }, streetViewControl: false }; } var map = gMap = new google.maps.Map(document.getElementById("sl_front_map_canvas"), mapOptions); var bounds = new google.maps.LatLngBounds(); var infoWindow = new google.maps.InfoWindow; var arrayData = []; var countryName = (jQuery('.sloc_browse li.selected a').attr('rel') != undefined) ? jQuery('.sloc_browse li.selected a').attr('rel') : ''; var sl_frontsearch_dal = { action: 'sl_dal_searchlocation', funMethod: 'LoadMapAndSet', Location: type, selValue: selValue, CateId: CatId, Country_name: countryName }; giz_Locator.home.ajaxSer(admin_ajx, "POST", sl_frontsearch_dal, function(markers){ if(markers != null){ if( markers.length 0){ iconImg = plugin_path + iconImg; markImage = new google.maps.MarkerImage(iconImg); } else{ iconImg = "http://www.google.com/intl/en_us/mapfiles/ms/micons/red-dot.png"; markImage = new google.maps.MarkerImage(iconImg); } } var marker = new google.maps.Marker({ map: map, position: point, icon: iconImg, animation: google.maps.Animation.DROP }); bounds.extend(point); var htmPhone =''; var htmFax =''; var htmEmail =''; var htmWeb =''; var htmLogo =''; var phone_fax =''; var htmLabel = ''; var htmlTiming = ''; var htmlDetails = ''; var add_width = (jQuery('#sloc_leftBar').width()-105) + 'px'; var Total_str = "Osoite :" + address; htmPhone = (Phone.length > 0) ? '
'+ Phone +', ' : '
'; if(Phone.length > 0) { Total_str = Total_str + ',Phone: ' + Phone; } htmFax = (fax.length > 0) ? ''+ fax +'
' : '
'; if(fax.length > 0) { Total_str = Total_str + ',Fax : ' + fax; } if(email.length > 0){htmEmail = ''; Total_str = Total_str + ',Email : ' + email;} if(web.length > 0){htmWeb = '
: '+ web +'
'; Total_str = Total_str + ',Website : ' + web;} if(logo.length > 0){htmLogo = '';} else{htmLogo = '';} htmLogo = ''; add_width = '99%'; phone_fax = htmPhone + htmFax; var path = window.location.protocol + "//" + window.location.host + '/products/StoreLocator/'; var orgin = window.location.protocol + "//" + window.location.host; var likeUrl = encodeURIComponent( main_path +'?Location=Social&StoreLocation='+ markers[i]["lat"] +"~"+ storeId + "~" + markers[i]["lng"]); var likeUrlN = main_path +'?Location=Social&StoreLocation='+ markers[i]["lat"] +"~"+ storeId + "~" + markers[i]["lng"]; var imageUrl = encodeURIComponent('http://maps.googleapis.com/maps/api/staticmap?center='+markers[i]["lat"]+','+markers[i]["lng"]+'&markers=color:red|'+markers[i]["lat"]+','+markers[i]["lng"]+'&zoom=15&size=851x315&sensor=false'); var imageUrlN = 'http://maps.googleapis.com/maps/api/staticmap?center='+markers[i]["lat"]+','+markers[i]["lng"]+'&markers=color:red|'+markers[i]["lat"]+','+markers[i]["lng"]+'&zoom=15&size=851x315&sensor=false'; var imageUrlFb = encodeURIComponent('http://maps.googleapis.com/maps/api/staticmap?center='+markers[i]["lat"]+','+markers[i]["lng"]+'&markers=color:red|'+markers[i]["lat"]+','+markers[i]["lng"]+'&zoom=10&size=150x150&sensor=false'); var fb ='
'; var pinit='
'; var tweet='
'; fb = (markers[i]["facebook"] === "1") ? fb : ""; pinit = (markers[i]["printrest"] === "1") ? pinit : ""; tweet = (markers[i]["twitter"] === "1") ? tweet : ""; var Social =''; var toolCss = ""; if(fb.length > 0 || pinit.length > 0 || tweet.length > 0){ toolCss = ""; }else{ toolCss = "no"; } var directionLink = (getDirections == "Popup") ? "javascript:void(0);" : "http://maps.google.com/maps?f=d&z=13&daddr="+ markers[i]["lat"] + ","+ markers[i]["lng"]; var directionsCss = (getDirections == "Popup") ? "sl_GetDirection" : "sl_GetDirection_1"; var directionTarget = (getDirections == "Popup") ? "" : "target='_blank'"; var directionhtm = 'Get Directions'; htmlTiming = (isStoreTime == 1) ? 'Load Store Timing' : ""; htmlDetails = (isAddiDetails == 1) ? 'More Info' : ""; if(labelId > 1){ htmLabel = '
'+ labelText +'
'; } var html = '
'+ htmLabel +'
'+ name +'
'+ htmLogo +'
'+ '
'+ address +'
'+ phone_fax + htmEmail + htmWeb + '