function mycarousel_initCallback(carousel) { // Disable autoscrolling if the user clicks the prev or next button. carousel.buttonNext.bind('click', function() { carousel.startAuto(0); }); carousel.buttonPrev.bind('click', function() { carousel.startAuto(0); }); // Pause autoscrolling if the user moves with the cursor over the clip. carousel.clip.hover(function() { carousel.stopAuto(); }, function() { carousel.startAuto(); }); }; // remap jQuery to $ $(document).ready(function() { $("#footerForm").validate(); $().UItoTop({ easingType: 'easeOutQuart' }); $('[id^="typeSearch_"]').each(function(index) { $(this).click(function() { GetFilteredVehiclesCount(); }); }); $("#perpage").change(function() { document.perpageform.submit(); }); $('.slideshow').cycle({ fx: 'fade' }); $('.slideshow2').cycle({ fx: 'fade', delay: '-3000', speed: '5500' }); $('.slideshow3').cycle({ fx: 'fade', delay: '-3000' }); // hover overs $(".carphoto").hover( function() { $(this).stop().animate({"opacity": "0.6"}, "slow"); }, function() { $(this).stop().animate({"opacity": "1"}, "slow"); }); $("#caractions a").hover( function() { $(this).stop().animate({"opacity": "0.6"}, "fast"); }, function() { $(this).stop().animate({"opacity": "1"}, "fast"); }); $(".fademe a").hover( function() { $(this).stop().animate({"opacity": "0.6"}, "fast"); }, function() { $(this).stop().animate({"opacity": "1"}, "fast"); }); jQuery('#mycarousel').jcarousel({ auto: 2, wrap: 'last', initCallback: mycarousel_initCallback }); startList = function() { if (document.all && document.getElementById) { var navRoot = document.getElementById("trans-nav"); for (i=0; i' + selmodel + ''); GetFilteredVehiclesCount(); }); //nice look inputs $("input, textarea, select, button").uniform(); //$.uniform.update("#ModelDropDown"); $('.popMe').popupWindow({ centerBrowser:1 , width:720, height:440, scrollbars:1 }); if ($('#title-valuation').length != 0) { //alert('help'); GetNewCaptcha(); } if ($('#thesearch').length != 0) { GetModels(0); } }); function GetFilteredVehiclesCount() { manuId = $('#MakeDropDown :selected').val(); modelId = $('#ModelDropDown :selected').val(); var vehType = ""; var vehTypeUrl = ""; $('[id^="typeSearch_"]').each(function(index) { if ($(this).is(':checked')) { vehType = $(this).val(); } }); if (vehType != "") { vehTypeUrl = "&vt=" + vehType } $.ajax( { type: "POST", data:"ajaxcall=true&did=" + dealerId + "&mid=" + manuId + "&mdid=" + modelId + vehTypeUrl, url: "howmany.asp", success: function (response) { //alert(response); if (response != "error") { $('#resultCount').text(response); } }, error: function (xhr, desc, err) { alert("Some error occured: " + xhr.responseText); } }); }