Jump to content

[solved] fix loading slider issue


Recommended Posts

Hi guys, i have some problem with two mainly modules that are in home page..I think the slider is in jquery or something-like.

I want that the products will be hidden while the page is loading..

how can i do this?

Link to comment
Share on other sites

edit css styles of sliders, add the "display:none" to the styles

 

then you can add / create jquery script:

 

jQuery(window).load(function () {
$("#block").show();
});

 

 

#block is the ID of the slider block you want to show.

Link to comment
Share on other sites

thanks for the reply, i have to hide this css item

.flexslider_carousel

and this is the js code

 $(document).ready(function(){

if (runFancy) {


$("#featured_products_slider li").hover(
 function () {
$("#featured_products_slider li").not(this).stop().fadeTo(400, 0.85);
 },
 function () {
 $("#featured_products_slider li").not(this).stop().fadeTo(400, 1.0);
 }
);   }


 });



 $(window).load(function() {
 $('#featured_products_slider').flexslider({

  namespace: "",
  animation: "slide",
  easing: "easeInQuart",
  slideshow: false,
  animationLoop: false,
  animationSpeed: 700,
  pauseOnHover: true,
  controlNav: false,
  itemWidth:  238,
  minItems: flexmin,					//{NEW} Integer: Minimum number of carousel items that should be visible. Items will resize fluidly when below this.
maxItems: flexmax,
  move: 0  });

$(window).resize(function() {
 try {
		$('#featured_products_slider').flexslider(0);
if($('#center_column').width()<=280){ $('#featured_products_slider').data('flexslider').setOpts({minItems: 1, maxItems: 1});
}
else if($('#center_column').width()<=440){ $('#featured_products_slider').data('flexslider').setOpts({minItems: 2, maxItems: 2});}
else if($('#center_column').width()<980){ $('#featured_products_slider').data('flexslider').setOpts({minItems: 3, maxItems: 3});}
else if($('#center_column').width()>=1240){ $('#featured_products_slider').data('flexslider').setOpts({minItems: 1, maxItems: 5});}
else if($('#center_column').width()>=990){ $('#featured_products_slider').data('flexslider').setOpts({minItems: 1, maxItems: 4});}

 } catch(e) {
		// handle all your exceptions here
	}
});
});

 

how can i apply what you said?

Edited by conidig (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...