var featureScroll = null; $(document).ready(function() { initSite(); }); function initSite() { //$(".pointsFeedWrap .emptyFeed").replaceWith('
ASCS National Sprint Carsas of 4/6/2013
Full Points
ASCS National Sprint Carsas of 4/6/2013
Full Points
ASCS National Sprint Carsas of 4/6/2013
Full Points
'); //if ($("div.resultsFeed .feedContent").length > 1) { // $("div.resultsFeed .feedContent").wrapAll("
"); // $(".resultsScrollable").before("<<>>"); // $("div.resultsFeedSub").scrollable({ clickable: false, loop: false, size: 1, keyboard: false, next: ".resultsNext", prev: ".resultsPrev", items: "div.resultsScrollable" }); //} //if ($("div.pointsFeed .feedContent").length > 1) { // $("div.pointsFeed .feedContent").wrapAll("
"); // $(".pointsScrollable").before("<<>>"); // $("div.pointsFeedSub").scrollable({ clickable: false, loop: false, size: 1, keyboard: false, next: ".pointsNext", prev: ".pointsPrev", items: "div.pointsScrollable" }); //} if ($(".headlineItem").length > 1) custScroll(700, 4000, -27, 'top', '.headlineWrap', '.headlineList', 'headlineItem'); $(".resultsFeedWrap h2").wrapInner("
").append("
").show(); if ($("body").attr("ID") == "homeBody") { $(".featureThumbsWrap").insertBefore($(".featureFeed")); $("#homeAboutWrap").insertAfter($(".featureFeedWrap")); $("#sponsorWrapper").insertAfter($(".featureFeedWrap")); $(".schFeedWrap h2, .pointsFeedWrap h2, .galleryFeedWrap h2, .videoFeedWrap h2, #homeAboutWrap h2").wrapInner("
").append("
").show(); } initSearchComplete(); startSite(); } function stopSite() { if (featureScroll != null) featureScroll.stop(); } function startSite() { //current scrollabe requires scrollables to be "played()" before they can be stopped....lame var t1 = 4500; var t2 = 7500; var t3 = 5500; initFeatured(); if ($("#sponsorWrapper .singleAdWrap").length > 4) { $("#sponsorWrapper").prepend($("#sponsorWrapper .singleAdWrap:eq(0)")); $("#sponsorWrapper .singleAdWrap:eq(0)").addClass("staticAd"); $("#sponsorWrapper .adWrap").css('width', '3000em').css('text-align', 'left'); custScroll(1200, 4000, -185, 'left', '#sponsorWrapperSub', '.adWrap', 'singleAdWrap'); } $(".headlineWrap").prepend("

Quick Info

"); } function initFeatured() { var featureScroll = null; if (!$(".featureFeedSub").is(":empty")) { $(".featureFeedWrap").prepend($(".featureThumbsWrap")); featureScroll = $(".featureFeed").scrollable({ vertical: true, clickable: false, loop: true, size: 1, keyboard: false, speed: 700, items: ".featureFeedSub", circular: true }).navigator(".featureThumbsWrap").autoscroll({ autoplay: false, interval: 4500, api: true }); $(".featureThumb:first").addClass("active"); if (featureScroll != null) { featureScroll.play(); } } } function initSearchComplete() { $(".mrp_input1 input[type='text']").autocomplete("/ui/autocomplete.aspx?ref=d-t", { scrollHeight: 200, width: 230, addTop: 9, addLeft: -12, delay: 100, max: 30, selectFirst: false, formatResult: function(item) { return item[0].replace(/(<.+?>)/gi, ''); } }).result(function(event, item) { location.href = item.attr("href"); }); }