Drupal.behaviors.mcstatus = function() { // alert('we are here'); $('#search .form-submit').val('Найти'); if ($("div#kontakty-map").length == 1) { anim_map = function () { $("div#kontakty-map img") .animate({"opacity": 0}, 12000, "linear") .animate({"opacity": 0}, 8000, "linear") .animate({"opacity": 1}, 12000, "linear"); }; anim_map(); setInterval(anim_map, 50000); } $('#header-slideshow').css({display: 'block'}); $('#header-slideshow:not(.behavior-processed)').addClass('behavior-processed').cycle({ fx: 'fade', // choose your transition type, ex: fade, scrollUp, shuffle, etc... timeout: 6000 }); $('#price-chooser select').change(function() { classes_to_show = $(this).val(); // console.log('classes_to_show ' + classes_to_show); classes_to_show = classes_to_show.replace(/\s+/g, '.').replace(/^/, '.'); // console.log('classes_to_show after replaces ' + classes_to_show); $('#price-list-table tbody tr').css({'display': 'none'}); $(classes_to_show).css({'display': ''});; }); if ($('#200x300').length !== 0 ) { flashvars = { link1: "http://mcstatus.ru/dna_diet" }; params = { menu: "false" }; attributes_200x300 = { id: "banner-200x300", name: "banner-200x300" }; swfobject.embedSWF("http://mcstatus.ru/sites/mcstatus.ru/files/flash_banners/300x250.swf", "200x300", "260", "218", "8.0.0","expressInstall.swf", flashvars, params, attributes_200x300); //alert('HereWeAre!'); } }