function subsite(){ //var aaaaaaa = ($('#subsection_c').height()+60+160); //alert(aaaaaaa); if( $(window).height() > ($('#subsection_c').height()+50+160+20) ){ $('#subsection_c').height( $(window).height()-50-160-20); /*if( $('#subsection_c').height()+50+160+20 <= $(window).height() ){ $('body').height( $(window).height() ); }else{ $('body').height( $('#subsection_c').height()+50+160+20 ); }*/ $('#subsection').height( $('#subsection_c').height()-20-120 ); //$('#subsection_in').height( $('#subsection').height() ); $('#subsection_inner').height( $('#subsection').height()-20 -35 -20 ); }else{ //$('#subsection_c').height( $('#subsection').height()+20 ); //console.log(1); } scrollpane = $('#subsection_inner').jScrollPane( {scrollbarWidth:8, scrollbarMargin:8} );//,showArrows:true } $(window).resize(function() { subsite(); }); //do promenny slideManagerImages da spravny obrazky do dany sekce //bud do #superbgimage vlozi obrazky nebo mu nastavi pozadi function superimage(){ slideManagerImages = new Array( "51_OLIVA - 001.jpg", "52_OLIVA - 003a.jpg", "53_OLIVA - 007.jpg", "54_OLIVA - 013.jpg", "55_OLIVA - 017.jpg", "58_OLIVA JIDLO - 024.jpg" ); var pictPath = "admin/pictures4flash/fullsize/"; var pictGenerator = "inc/slidemanager_image.php?ww="+$(window).width()+"&wh="+($(window).height())+"&url="; //if ( slideManagerImages.length == 1 ) { // $('#superbgimage').css( 'background-image', 'url("'+pictGenerator + pictPath + slideManagerImages[0]+'")' ); //} else { var html = ""; for ( pict in slideManagerImages ){ html += ''; } $('#superbgimage').html( html ); $('#superbgimage img').css("visibility", "visible"); // Options for SuperBGImage $.fn.superbgimage.options = { z_index:0, inlineMode: 0, slideshow: 1, // 0-none, 1-autostart slideshow slide_interval: 5000, // interval for the slideshow transition: 1, transitionout: 0, speed: 2000 // animation speed }; $('#superbgimage').superbgimage(); //} } // initialise plugins jQuery(function(){ jQuery('ul.sf-menu').superfish({ delay: 200, pathClass: 'current', speed: 'fast' }); }); $(document).ready(function() { subsite(); })