<%staging.holtcat.com
storeTypeIdParam = request("storeTypeIds")
if(request("storeTypeIds") = "")then
        storeTypeIdParam="0"
end if
zipcodeParam = request("zipcode")
if(request("zipcode") = "") then
        zipcodeParam="78701"
end if
lat = request("lat")
lon = request("lon")
distance = request("distance")
if(request("lat") = "") then
        lat = 30.2
end if
if(request("lon") = "") then
        lon = -97
end if
if(request("distance") = "") then
        distance = 100
end if
function createLocationArray(storeTypeIdParam,startLat,startLon,radius)
                set conn=Server.CreateObject("ADODB.Connection")
                conn.Open "Provider=SQLOLEDB; Data Source=staging.holtcat.com; Initial Catalog=HoltCAT_WebApps;User ID=storelocator1; Password=riptide54"
                idFilter = " and storetypeservice_id in (" & storeTypeIdParam & ")"
                distanceFunc = " storelocator1.GetDistance(" & startLat & "," & startLon & ",shipping_lat,shipping_long)"
                
                                radius = "(select top 1 distance from distanceradius)"
                distanceFilter = " and " & distanceFunc & " < " & radius
                
                getAddressSql = "select ( rtrim(location_name) + '<br/>' + rtrim(shipping_address) + '<br/>' + rtrim(shipping_city) + '<br/>' + rtrim(shipping_zip) + '<br/>' + rtrim(shipping_country) + '<br/><br/>' + rtrim(shipping_phone)) as shipping_address,rtrim(shipping_long),rtrim(shipping_lat)," & distanceFunc & " as distance  from location l left outer join location_to_storetypeservice r on l.id = r.location_id where 1=1"
                
                
                
                if not IsNull(storeTypeIdParam) and storeTypeIdParam <> "0" then
                        getAddressSql = getAddressSql & idFilter
                end if
                
                getAddressSql = getAddressSql + distanceFilter & " order by distance asc"
                response.write("<script> $(function() {")
                set rs=  conn.execute(getAddressSql)            
                if not rs.eof then
                rsArray = rs.GetRows()
                theCount = UBound(rsArray, 2) + 1 
                                
                Dim locations()
                ReDim locations(theCount)
                
                iRecFirst   = LBound(rsArray, 2)
                iRecLast    = UBound(rsArray, 2)
                firstIter = true
                                
                For I = iRecFirst To iRecLast
                shippingAddress = rsArray(0,I)
                shipLong = rsArray(1,I)           
                shipLat = rsArray(2,I)          
                distanceXY = rsArray(3,I)
                                if(firstIter) then
                                response.write( "showAddress('" & shippingAddress & "'," &  shipLat & "," & shipLong &"," & distanceXY & ");")
                                else
                response.write( "addAddress('" & shippingAddress & "'," &  shipLat & "," & shipLong &"," & distanceXY & ");")
                                end if
                                firstIter=false
                Next
                
                end if
                response.write("});</script>")
                rs.close
                conn.Close
end function
function writeLocationDiv(storeTypeIdParam,startLat,startLon,radius)
                set conn=Server.CreateObject("ADODB.Connection")
                conn.Open "Provider=SQLOLEDB; Data Source=staging.holtcat.com; Initial Catalog=HoltCAT_WebApps;User ID=storelocator1; Password=riptide54"           
                idFilter = " and id in (select location_id  from storelocator1.location_to_storetypeservice where location_id = l.id and storetypeservice_id in (" & storeTypeIdParam & ") )"
                distanceFunc = " storelocator1.GetDistance(" & startLat & "," & startLon & ",shipping_lat,shipping_long)"
                
                                radius = "(select top 1 distance from distanceradius)"
                distanceFilter = " and " & distanceFunc & " < " & radius
                
                getAddressSql = "select (rtrim(shipping_address) + '<br/>  ' + rtrim(shipping_city) + ' ' + rtrim(shipping_zip) +  ' ' +  rtrim(shipping_country) + '<br/>  ' + rtrim(shipping_phone)) as shipping_address,rtrim(shipping_long),rtrim(shipping_lat)," & distanceFunc & " as distance, rtrim(location_name) as name, l.location_desc as location_desc, ltrim(rtrim(location_url)),id as location_id, location_image from location l where 1=1"
      
                if not IsNull(storeTypeIdParam) and storeTypeIdParam <> "0" then
                        getAddressSql = getAddressSql & idFilter
                end if
                
                getAddressSql = getAddressSql & distanceFilter
                                getAddressSql = getAddressSql & " order by distance asc"
                set rs2=  conn.execute(getAddressSql)           
                if not rs2.eof then
                rs2Array = rs2.GetRows()
                theCount = UBound(rs2Array, 2) + 1 
                                
                Dim locations()
                ReDim locations(theCount)
                
                iRecFirst   = LBound(rs2Array, 2)
                iRecLast    = UBound(rs2Array, 2)
                response.write("<table style='width:100%;' class='resultsTable'> <tr> <th style='text-align:left;'>Store</th>  <th style='text-align:left;'> Distance </th> <th style='text-align:left;'> Store Type / Services</th>")    
                For I = iRecFirst To iRecLast
                shippingAddress = rs2Array(0,I)
                shipLong = rs2Array(1,I)                  
                shipLat = rs2Array(2,I)         
                distanceXY = round(rs2Array(3,I),2)
                companyNameXY = rs2Array(4,I)
                locDesc  = rs2Array(5,I)                
                locationUrl = rs2Array(6,I)
                                location_id = rs2Array(7,I)
                                imgLocation = rs2Array(8,I)
                storeTypesDesc = ""
                                storeImgLink = "<img src='./admin/location_images/" &imgLocation &"' style='float:right;width:65px;height:100px;' alt=''/>"
                                if(imgLocation="" or isNull(imgLocation)) then
                                storeImgLink = ""
                                end if
                                
                                set conn3=Server.CreateObject("ADODB.Connection")
                conn3.Open "Provider=SQLOLEDB; Data Source=staging.holtcat.com; Initial Catalog=HoltCAT_WebApps;User ID=storelocator1; Password=riptide54"           
                                
                                getServices = "select servicename from storelocator1.storetypeservice where 1=1 "                       
                if not IsNull(location_id) and location_id <> "" then
                                getServices = getServices & " and id in (select storetypeservice_id from location_to_storetypeservice  where location_id = " & location_id & ")"
                                else
                                getServices = getServices & " and 2=1"
                                end if
                        
                        
                                set rs3=  conn.execute(getServices)           
                do while not rs3.eof 
                storeTypesDesc = storeTypesDesc & "<br/> - " & rs3(0) 
                                rs3.movenext
                                getServices = ""
                                loop
                                
                                conn3.Close
                                
                                
                                
                response.write( "<tr class='resultsRow'><td><div style='float:left'>" & companyNameXY & "<br/>" & shippingAddress & "</div>" & storeImgLink & "</td><td>" & distanceXY & "</td><td>" & storeTypesDesc & "<a target='_blank' href='" &  locationUrl & "' style='float:right;'><img src='moreinfobutton.jpg' style='border-style:none;'></a></td></tr>" )
                
                                Next
                
                end if
                response.write("</table")
                rs2.close
                conn.Close
end function
function printStoreList(zipcodeFilter,storeTypeFilter)          
        set conn=Server.CreateObject("ADODB.Connection")
        conn.Open "Provider=SQLOLEDB; Data Source=staging.holtcat.com; Initial Catalog=HoltCAT_WebApps;User ID=storelocator1; Password=riptide54"
                getServicesSQL = "SELECT * FROM storetypeservice l left outer join storetype r  on l.storetypeid = r.id  order by storetypeid"
                response.write("Filter by:<br/>")
                response.write("<ul class='storeTypeUL' style='list-style-type:none;'>")
                prev_store_type = ""
                set rs=  conn.execute(getServicesSql)           
                if not rs.eof then
                  do
                        storetypename = rs("storetypename")               
                        service_name=rs("servicename").value            
                        serviceid = rs(0)                       
                        if prev_store_type = "" then
                        response.write("<li style='list-style-type:none;'> <span class='storeTypeDesc' style='list-style-type:none;'><input type='checkbox' value='false'>" & storetypename & "</span><ul class='storeTypeSubUL' style='list-style-type:none;'>")
                        end if
                        if not prev_store_type = storetypename and prev_store_type <> ""  then 
                                response.write("</ul></li> <li style='list-style-type:none;'><span class='storeTypeDesc' style='list-style-type:none;'><input type='checkbox'>" & storetypename &"</span><ul class='storeTypeSubUL' style='list-style-type:none;'>")            
                        end  if
                        
                        response.write("<li style='list-style-type:none;'><input class='storetypenameCheckbox' type='checkbox' value='" & serviceid & "'>" & service_name & " </input></li>")
                        rs.movenext
                        
                        prev_store_type = storetypename
                  loop until rs.eof
                end if
                rs.close
                set rs=nothing  
                response.write("</ul><li style='list-style-type:none;'><input class='storetypenameCheckbox' type='checkbox' value='0'> Show All </input></li>")
                
                response.write("</ul>")
                conn.Close
end function
//getServicesSQL = "SELECT * FROM storetypeservice l left outer join storetype r  on l.storetypeid = r.id  where storetypeid in (" & storeTypeIdParam & ") order by storetypeid"
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml">
  <head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
    <style type="text/css">
        ul
        {
                list-style:none;
        }
        li
        {
                list-style:none;
        }
        .storeTypeUL
        {
                    list-style:none;
                                        color:white;
                
        }
        
        .storeTypeSubUL
        {
                    list-style:none;    
                        display:none;
        }
                
                .resultsTable tr
                {
                        background-image:url('./images/resultsbkg.jpg');
                        background-repeat:repeat;
                }
                .resultsTable td
                {
                        border-right:solid 1px gray;
                }
        
		.storeTypeDesc  { color:white; }
		.storetypenameCheckbox { color:white;}
    </style>
    <title>
      Store Locator Module
    </title><% response.write("<script> var storeTypeIdParam ='" & storeTypeIdParam & "'; var zipCodeParam='"  & zipcodeParam & "'; </script>") %>
    <script type="text/javascript" src=
    "http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.min.js">
</script>
<!--<script src="http://maps.google.com/maps?file=api&amp;v=2.x&amp;key=ABQIAAAAzr2EBOXUKnm_jVnk0OJI7xSosDVG8KKPE1-m51RBrvYughuyMxQ-i1QfUnH94QxWIa6N4U6MouMmBA" type="text/javascript"></script>-->
    <script src=
    "http://maps.google.com/maps?file=api&amp;v=2.x&amp;key=ABQIAAAAQryd-w6-X5b_UdYpEYhyDBRbgf94KYWJwZ5p9y46niQYZXt6vBSnsqrbgc7aBOzLSV3l9EL4oo845Q"
    type="text/javascript">
</script>
    <script type="text/javascript">
//<![CDATA[
    var map = null;
    var geocoder = null;
        
                $(function() 
                {
                        $('.storeTypeDesc input').click( function() {
						
                                $(this).parent().parent().find('.storeTypeSubUL').toggle();
                        });
						
                        
                        $('.resultsRow').hover(function() {
                        $(this).css("background-color","#bce3f8");
                        },function() {
                        $(this).css("background-color","white")
                        });
                        
                        
                                $("#additionFiltersButton").toggle(function(){
        
                                                        $("#additionFilters").hide();
                                                        $("#additionFiltersButton img").attr("src","right-arrow.png");
                                                },
                                                function(){
                                                                $("#additionFilters").show();
                                                                $("#additionFiltersButton img").attr("src","downarrow.png");
                                                }
                                                );
                        
                }
                );
          function showAddress(address,ship_lat,ship_long,distance) { 
              map.setCenter(new GLatLng(ship_lat,ship_long), 7);
                              
                          var location = new GLatLng(ship_lat,ship_long);
                          
              var marker = new GMarker(location)
              map.addOverlay(marker);
                           GEvent.addListener(marker, "click", function() { 
                                        marker.openInfoWindowHtml("<b>" + address + "<\/b>");
                                });
              marker.openInfoWindowHtml(address);
                         
            }
          function addAddress(address,ship_lat,ship_long,distance) {
        
              var location = new GLatLng(ship_lat,ship_long);                     
              var marker = new GMarker(location)
                          map.addOverlay(marker);
                          
                           GEvent.addListener(marker, "click", function() { 
                                        marker.openInfoWindowHtml("<b>" + address + "<\/b>");
                                });
                                
              //marker.openInfoWindowHtml(address);
                         
            }
        function centerToAddress(address) {
          geocoder.getLatLng(
                address,
                function(point) {
                  if (!point) {
                        alert(address + " not found");
                  } else {
                        map.setCenter(point, 11);
                        //var marker = new GMarker(point);
                        //map.addOverlay(marker);
                        //marker.openInfoWindowHtml(address);
                  }
                }
          );
    }
                
    function initialize() {
      if (GBrowserIsCompatible()) {
        map = new GMap2(document.getElementById("map_canvas"));
       // map.setCenter(new GLatLng(30.1963110,-97.7308070), 13);
           
        geocoder = new GClientGeocoder();
                map.setUIToDefault() 
      }
    }
        
        function getStoreTypeIds() {
                        var idArray = '';       
                        $('.storetypenameCheckbox[@type=checkbox][@checked]').each( function() 
                        {       
                                
                                idArray = idArray + $(this).attr('value') + ",";
                        });
                        return idArray.substring(0,idArray.length-1);
        }
                
        function restoreFromPostBack()  {
        
                var sParams = storeTypeIdParam.split(',');
                for(var i in sParams)
                {
        
                        strMatch = '.storetypenameCheckbox[value=' + sParams[i] + ']';
                        $(strMatch).attr('checked', true);
        
                        $('.storetypenameCheckbox[@checked]').parent().parent().parent().find('span').find('input').attr('checked',true);
                        $(strMatch).parent().parent().show();
                }
                
                $('#zipcodeInput').attr('value',zipCodeParam);
                //
        }
        
        $(                      
                function () {
                                                
                        // Show all is mutally exclusive from rest of set
                        // this code defines that behaviour
                        $('.storetypenameCheckbox[value=0]').click(function() {
                                $('.storetypenameCheckbox[value!=0]').attr('checked',false);
                        }
                        );
                        
                        
                        $('.storetypenameCheckbox[value!=0]').click(function() {
                                $('.storetypenameCheckbox[value=0]').attr('checked',false);
                        }
                        );
                        
                        
                        restoreFromPostBack();
                                                
                        initialize();
                        // address just for display, map centered at coords
                        centerToAddress(zipCodeParam); 
                        }
        );
        
        function buildGetRequest(baseUrl,storeTypeIds,zipcode,lon,lat,distance) {
                var newUrl = baseUrl; 
                newUrl += "?zipcode=" + zipcode;
                newUrl += "&storeTypeIds=" + storeTypeIds;
                newUrl += "&lon=" + lon;
                newUrl += "&lat=" + lat;
                newUrl += "&distance=" + distance;
                return newUrl;
        }
        
        function doGetRequest(lon,lat,storeTypeIds,zipcode) 
        {
                
                var distance = 100;
            var baseUrl = window.location.pathname;
                var newRequest = buildGetRequest(baseUrl,storeTypeIds,zipcode,lon,lat,distance);                
                window.location = newRequest;
        }
        
        function updateGoogleMap() {
                // convert zipcode to coordinates
                
                // add lon,lat,distance to query params
                
                var storeTypeIds = getStoreTypeIds();
                var zipcode = $('#zipcodeInput').attr('value');
        
                
                  geocoder.getLatLng(
                        zipcode,
                function(point) { 
                        doGetRequest(point.x,point.y,storeTypeIds,zipcode);
                }
          );
          
                
        }
        
        
        
                
    //]]>
    </script><!-- RIPPED HEADERS -->
    <style id="StylePlaceholder" type="text/css">
</style>
    <link id="_Portals__default_" rel="stylesheet" type="text/css" href=
    "/Portals/_default/default.css" />
    <link id="_Portals_0_Skins_HoltCat_subpage_css" rel="stylesheet" type="text/css" href=
    "/Portals/0/Skins/HoltCat/subpage.css" />
    <link id="_Portals_0_Containers_LeftMenu_LeftMenu_css" rel="stylesheet" type="text/css" href=
    "/Portals/0/Containers/LeftMenu/LeftMenu.css" />
    <link id="_Portals_0_Containers_main_" rel="stylesheet" type="text/css" href=
    "/Portals/0/Containers/main/container.css" />
    <link id="_Portals_0_Containers_main_container_css" rel="stylesheet" type="text/css" href=
    "/Portals/0/Containers/main/container.css" />
    <link id="_Portals_0_Containers_Did_You_Know_" rel="stylesheet" type="text/css" href=
    "/Portals/0/Containers/Did_You_Know/container.css" />
    <link id="_Portals_0_Containers_Did_You_Know_Container_css" rel="stylesheet" type="text/css"
    href="/Portals/0/Containers/Did_You_Know/Container.css" />
    <link id="_Portals_0_Containers_Related_Links_" rel="stylesheet" type="text/css" href=
    "/Portals/0/Containers/Related_Links/container.css" />
    <link id="_Portals_0_Containers_Related_Links_Container_css" rel="stylesheet" type="text/css"
    href="/Portals/0/Containers/Related_Links/Container.css" />
    <link id="_Portals_0_" rel="stylesheet" type="text/css" href=
    "/Portals/0/portal.css" /><!-- RIPPED HEADERS -->
    <style type="text/css">
/*<![CDATA[*/
    div.c11 {width:766px;background-color:white;padding:15px;margin:10px}
    table.c10 {width:100%}
    td.c9 {width:100%;background-image:url(graybg.png);background-repeat:repeat;}
    ul.c8 {list-style-type:none;}
    li.c7 {list-style-type:none;}
    span.c6 {list-style-type:none;}
    td.c5 {background-color:black;padding:3px;color:white;}
    form.c4 {height:27px}
    img.c3 {cursor:pointer;}
    label.c2 {font-weight:bold;}
    div.c1 {width: 100%; height: 300px}
    /*]]>*/
    </style>
    <style type="text/css">
/*<![CDATA[*/
    tr.c8 {display:none;}
    td.c7 {text-align:top;}
    img.c6 {width:10px;}
    li.c5 {display:inline;}
    span.c4 {color:#d7b846; font-weight:bold; font-size:medium;}
    img.c3 {vertical-align:middle;}
    input.c2 {vertical-align:middle;}
    label.c1 {vertical-align:middle;}
    /*]]>*/
    </style>
  </head>
  <body onload="" onunload="GUnload()">
    <script type="text/javascript">
</script>
    <div id="moduleContainer" class="c11">
      <table class="c10" cellpaddinng="0" cellspacing="0">
        <tr>
          <td>
            <div id="map_canvas" class="c1"></div>
          </td>
        </tr>
        <tr>
          <td class="c5">
            <form action="#" onsubmit="updateGoogleMap(); return false" class="c4">
              <%                      
                                            createLocationArray storeTypeIdParam, lat,lon,distance
                                    %><label class="c2 c1">Enter Your Zipcode to find HOLTCAT
              Locations close to you:</label> <input id="zipcodeInput" type="text" size="18"
              name="address" class="c2" /> <img class="c3 c3" src="searchbutton.jpg" onclick=
              "updateGoogleMap();" alt="Image" />
            </form>
          </td>
        </tr>
        <tr>
          <td class="c9">
            <table>
              <tr>
                <td colspan="3">
                  <table >
                    <tr>
                      <td style="vertical-align:top;">
                        <span class="c4">Filter by Product Type:</span>
                      </td>
                      <td style="vertical-align:top;">
                        <span>
                          <span class='c7 c5' style="padding:0px; margin:0px;">
						 
                            <span class='storeTypeDesc'><input type='checkbox' style="color:white;" />HOLTCat</span>
                         
                   
                        <span class='storeTypeSubUL c8'>
						 <br/>
                          <span class='c7' style="color:white;">
                            <input class='storetypenameCheckbox' type='checkbox' value=
                            '9' />Sales,Parts,Service
                          </span>
                        </span>
						 </span>
						      </span>
                      </td>
                      <td style="vertical-align:top;">
                        <span>
						
                          <span class='c7 c5'>
                            <span class='storeTypeDesc c6'><input type='checkbox'  style="color:white;" />HOLTCrane</span>
                          
                      
                        <span class='storeTypeSubUL c8'>
						<br/>
                          <span class='c7' style="color:white;" >
                            <input class='storetypenameCheckbox' type='checkbox' value=
                            '9' "  />Sales,Parts,Service
                          </span>
                        </span>
						</span>
						  </span>
                      </td>
                      <td style="vertical-align:top;">
                        <span>
                          <span class='c7 c5'>
                            <span class='storeTypeDesc c6'><input type='checkbox' />Holt Ag</span>
                          
                       
                        <span class='storeTypeSubUL c8'>
						<br/>
                          <span class='c7' style="color:white;">
                            <input class='storetypenameCheckbox' type='checkbox' value=
                            '9' />Sales,Parts,Service
                          </span>
                        </span>
						</span>
						 </span>
                      </td>
                    </tr>
                  </table>
                </td>
              </tr>
              <tr>
                <td colspan="3">
                  <span class="c4">Additional Filters :</span> <span id=
                  "additionFiltersButton"><img class="c6" src='right-arrow.png' alt=
                  "Image" /></span>
                </td>
              </tr>
              <tr id="additionFilters" class="c8">
                <td>
                  <ul class='storeTypeUL c8'>
                    <li class='c7'>
                      <span class='storeTypeDesc c6'><input type='checkbox' value='false' />Cat
                      Machine</span>
                      <ul class='storeTypeSubUL c8'>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='1' />Sales
                          &amp; Heavy Rental
                        </li>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='2' />Parts
                          &amp; Service
                        </li>
                      </ul>
                    </li>
                    <li class='c7'>
                      <span class='storeTypeDesc c6'><input type='checkbox' />Industrial Engine and
                      Generator</span>
                      <ul class='storeTypeSubUL c8'>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='3' />Sales
                          &amp; Rental
                        </li>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='4' />Parts
                        </li>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='5' />Service
                        </li>
                      </ul>
                    </li>
                    <li class='c7'>
                      <span class='storeTypeDesc c6'><input type='checkbox' />On-Highway
                      Truck/RV</span>
                      <ul class='storeTypeSubUL c8'>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='7' />Parts
                        </li>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='8' />Service
                        </li>
                      </ul>
                    </li>
                    <li class='c7'>
                      <span class='storeTypeDesc c6'><input type='checkbox' />Machine Engine</span>
                      <ul class='storeTypeSubUL c8'>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value=
                          '10' />Sales,Parts,Service
                        </li>
                      </ul>
                    </li>
                    <li class='c7'>
                      <span class='storeTypeDesc c6'><input type='checkbox' />HOLT Rental
                      Services</span>
                      <ul class='storeTypeSubUL c8'>
                        <li class='c7'>
                          <input class='storetypenameCheckbox' type='checkbox' value='11' />Light
                          Rental
                        </li>
                      </ul>
                    </li>
                  </ul>
                </td>
                <td class="c7" valign="top">
                  <ul class="storeTypeUL">
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='13' />Hydraulic
                      Repair
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='14' />Custom
                      Engineered Products &amp; Services
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='15' />Scheduled
                      Oil Sampling (HOLT Oil Lab)
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='16' />Scheduled
                      Maintenance (CSAs)
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='17' />Radiator
                      Repair
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='18' />Welding and
                      Machining
                    </li>
                  </ul>
                </td>
                <td valign="top">
                  <ul class="storeTypeUL">
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='19' />Machine
                      Rebuilds
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='20' />Industrial
                      Engine Rebuilds
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='21' />Track
                      Service
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='22' />Lube
                      Service
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='23' />Painting
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='24' />Technical
                      Services
                    </li>
                    <li class='c7'>
                      <input class='storetypenameCheckbox' type='checkbox' value='0' />Show All
                    </li>
                  </ul>
                </td>
              </tr>
            </table>
          </td>
        </tr>
        <tr>
          <td>
            <% 
                                    if(request("zipcode") <> "") then
                                    writeLocationDiv storeTypeIdParam, lat,lon,distance 
                                    end if
                                    %>
          </td>
        </tr>
      </table>
    </div>
  </body>
</html>
.dd_menubar {
	height: 41px;
	background-image: url(images/ddmenu/menubarbg.png);
	background-position: top left;
	background-repeat: repeat-x;
}
.dd_navlink {
	margin-left: 15px;
	font-family: Geneva, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: bold;
	color: #333;
	text-decoration: none;
}
.dd_navlinkimg {
	margin: 0px;
	border: 0px;
}
.dd_navlinkhover {
	position: absolute;
	border: 0px;
	padding: 0px;
	z-index: 4999;
	margin: 0px;
}
.dd_menu {
	position: absolute;
	left: 200px;
	top: 300px;
	display: none;
	filter: alpha(opacity=95);
	-moz-opacity: .95;
	opacity: .95;
	z-index:10000;
}
.dd_menu_inner {
	min-height: 50px;
	width: 100%;
	display: table;
	position: relative;
}
.dd_menu_borderimg {
	margin: auto;
	padding: 0px;
	border: 0px;
	font-size: 1px;
}
.dd_menu_border_lt {
	/*background-image: url(images/ddmenu/menubg_lt.png);*/
	background-position: top left;
	background-repeat: no-repeat;
	position: absolute; 
	left: 0px; 
	top: 0px; 
	width:7px; 
	height: 9px;
}
.dd_menu_border_rt {
	/*background-image: url(images/ddmenu/menubg_rt.png);*/
	background-position: top left;
	background-repeat: no-repeat;
	position: absolute; 
	right: 0px; 
	top: 0px; 
	width:4px; 
	height: 9px;
}
.dd_menu_border_t {
	/*background-image: url(images/ddmenu/menubg_t.png);*/
	background-position: top left;
	background-repeat:repeat-x;
	margin: 0px;
	margin-left: 7px;
	margin-right: 4px;
	#margin-right:0px;
	#margin-left:0px;
	_margin-left:0px;
	_margin-right:0px;
	z-index: 1001;
}
.dd_menu_border_lb {
	/*background-image: url(images/ddmenu/menubg_lb.png);*/
	background-position: top left;
	background-repeat: no-repeat;
	position: absolute; 
	left: 0px; 
	top: 0px; 
	width:7px; 
	height: 5px;
}
.dd_menu_border_rb {
	/*background-image: url(images/ddmenu/menubg_rb.png);*/
	background-position: top left;
	background-repeat: no-repeat;
	position: absolute; 
	right: 0px; 
	top: 0px; 
	width:4px; 
	height: 5px;
}
.dd_menu_border_b {
	/*background-image: url(images/ddmenu/menubg_b.png);*/
	background-position: top left;
	background-repeat:repeat-x;
	margin: 0px;
	margin-left: 7px;
	margin-right: 4px;
	z-index: 1001;
	#margin-right:0px;
	#margin-left:0px;
	_margin-left:0px;
	_margin-right:0px;
	#margin-top:-1px;
	#border-top:solid 2px #F6CA20;
	#padding-top:2px;
}
.dd_menu_border_l {
	/*background-image: url(images/ddmenu/menubg_l.png);*/
	background-position: top left;
	background-repeat: repeat-y;
}
.dd_menu_border_r {
	/*background-image: url(images/ddmenu/menubg_r.png);*/
	background-position: top right;
	background-repeat: repeat-y;
}
.dd_section {
	float: left;
	clear: none;
	background-color: #f6ca22;
	width: 200px;
	display: table;
	margin-top: -11px;
	position: relative;
	padding-right: 10px;
	padding-left: 20px;
}
.dd_sectiondiv {
	position: absolute;
	top: 10px;
	right: 0px;
}
.dd_link {
	font-family: Geneva, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: normal;
	color: #333333;
	text-decoration: none;
	margin-top: 4px;
	margin-bottom: 3px;
	float: left;
	clear: both;
	margin-right: 10px;
	display:inline;
	width: 100%;
	!important;
}
.dd_link:active {
	font-family: Geneva, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: normal;
	color: #333333;
	text-decoration: none;
	margin-top: 4px;
	margin-bottom: 3px;
	float: left;
	clear: both;
	margin-right: 10px;
	display:inline;
	width: 100%;
	!important;
}
.dd_link:link {
	font-family: Geneva, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: normal;
	color: #333333;
	text-decoration: none;
	margin-top: 4px;
	margin-bottom: 3px;
	float: left;
	clear: both;
	margin-right: 10px;
	display:inline;
	width: 100%;
	!important;
}
.dd_link:visited {
	font-family: Geneva, Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: normal;
	color: #333333;
	text-decoration: none;
	margin-top: 4px;
	margin-bottom: 3px;
	float: left;
	clear: both;
	margin-right: 10px;
	display:inline;
	width: 100%;
	!important;
}
.dd_link:hover {
	text-decoration: underline;
	!important;
}
.dd_linkhead {
	font-family: Geneva, Arial, Helvetica, sans-serif;
	font-size: 13px;
	font-weight: bold;
	color: #000000;
	text-decoration: none;
	margin-top: 4px;
	margin-bottom: 7px;
	margin-top: 10px;
	float: left;
	clear: both;
	margin-right: 20px;
	!important;
	}
.dd_linkhead:active {
	text-decoration: none;
	color: #000000;
	!important;
}
.dd_linkhead:link {
	text-decoration: none;
	color: #000000;
	!important;
}
.dd_linkhead:visited {
	text-decoration: none;
	color: #000000;
	!important;	
}
.dd_linkhead:hover {
	text-decoration: underline;
	color: #000000;
	!important;	
}
.dd_level1 {
	margin-left: 0px;
}
.dd_level1 a:active{
	margin-left: 0px;
	color:#333;
}
.dd_level1 a:link{
	margin-left: 0px;
	color:#333;
}
.dd_level1 a:visited{
	margin-left: 0px;
	color:#333;
}
.dd_level1 a:hover{
	margin-left: 0px;
	color:#000000;
}
.dd_level2 {
	margin-left: 20px;
}
.dd_level3 {
	margin-left: 40px;
}
.dd_level4 {
	margin-left: 80px;
}
