Nic727 Posted December 9, 2014 Share Posted December 9, 2014 Hi, I put a simple carousel on my website and I have a strange bug and I don't know how to resolve it. I tried everything...I made a small video about that : http://depositfiles.com/files/by2uq5xl3 What do you think? I'm not able to see my teacher toomorow and that's sad. Thank you and sorry for all my questions/problems. Link to comment Share on other sites More sharing options...
tejasamrute Posted December 9, 2014 Share Posted December 9, 2014 the link which you attached is not working......Can you upload your code on a server n show what wrong is happening? Link to comment Share on other sites More sharing options...
Nic727 Posted December 10, 2014 Author Share Posted December 10, 2014 (edited) hum... The link work for me. Try on my server : http://aqua.nicolas-duclos.com/capture-2My code : <div id="carousel-example" class="carousel slide" data-ride="carousel" style="border:2px solid #e1e1e1;"> <div class="carousel-inner"> <div class="item active"> <a href="img/1.jpg" data-lightbox="image-1" data-title="My caption"><img src="img/1.jpg" alt="" /></a> </div> <div class="item"> <a href="img/2.jpg" data-lightbox="image-1" data-title="My caption"><img src="img/2.jpg" alt="" /></a> </div> <div class="item"> <a href="img/3.jpg" data-lightbox="image-1" data-title="My caption"><img src="img/3.jpg" alt="" /></a> </div> </div> <!--INDICATORS--> <ol class="carousel-indicators"> <li data-target="#carousel-example" data-slide-to="0" class="active"></li> <li data-target="#carousel-example" data-slide-to="1"></li> <li data-target="#carousel-example" data-slide-to="2"></li> </ol> <!--PREVIUS-NEXT BUTTONS--> <a class="left carousel-control" href="#carousel-example" data-slide="prev"> <span class="glyphicon glyphicon-chevron-left"></span> </a> <a class="right carousel-control" href="#carousel-example" data-slide="next"> <span class="glyphicon glyphicon-chevron-right"></span> </a></div> Edited December 10, 2014 by Nic727 Link to comment Share on other sites More sharing options...
Ingolme Posted December 10, 2014 Share Posted December 10, 2014 We can't know what the browser is doing just by seeing a video. We need to see a working page where we can analyze the DOM and check for Javascript errors. Link to comment Share on other sites More sharing options...
Nic727 Posted December 10, 2014 Author Share Posted December 10, 2014 (edited) http://aqua.nicolas-duclos.com scroll down for carousel. Edited December 10, 2014 by Nic727 Link to comment Share on other sites More sharing options...
Ingolme Posted December 10, 2014 Share Posted December 10, 2014 I think this is the source of your problem in your stylesheet: moncss.css .left{float: left;}.right{float: right;} The carousel dynamically adds classes "left" or "right" during the transition and your stylesheet is interfering. Change these class names to something else Link to comment Share on other sites More sharing options...
dsonesuk Posted December 10, 2014 Share Posted December 10, 2014 The slide image is returning to its original size, you need to set a height for container window. You could get current height of container when page first loads, then set the height of images to that. Link to comment Share on other sites More sharing options...
Ingolme Posted December 10, 2014 Share Posted December 10, 2014 The slide image is returning to its original size, you need to set a height for container window. You could get current height of container when page first loads, then set the height of images to that. That would be a way to patch it up, but I prefer to solve problems right from their root. Bootstrap's carousel script is supposed to take care of the image sizes without the need of extra styling. The reason the image is returning to its original size unexpectedly is because he is overriding the carousel's "left" and "right" classes in his stylesheet. Link to comment Share on other sites More sharing options...
dsonesuk Posted December 10, 2014 Share Posted December 10, 2014 Then he does not need to change class names, and change the root design on how the slideshow functions, he just needs to disable the .left, .right from applying float in carosel specifically. Link to comment Share on other sites More sharing options...
Nic727 Posted December 11, 2014 Author Share Posted December 11, 2014 Thank you I will try that! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now