jquery - FlexSlider 2: captions over image are shifting nav controls -


trying configure flexslider same way shows on homepage of flexslider website. =)

http://www.woothemes.com/flexslider/

which has captions on image using transparent background.

the following code works, except nav controls - shifted way down.

http://jsfiddle.net/amdlp/1/

css:

#homepage-images img {     display: block;     height: 350px; }  #homepage-images li {     position: relative; }  #homepage-images .flex-caption {     position: absolute;     bottom: 0;     left: 0;     margin: 0;     padding: 10px;     color: white;     background-color: rgba(0,0,0,0.5); } 

html:

<div id='homepage'>   <div id='homepage-images' class='flexslider'>     <ul class='slides'>       <li><img src='content/homepage/images/1.jpg' alt=''><p class='flex-caption'>some captions</p></li>       <li><img src='content/homepage/images/2.jpg' alt=''><p class='flex-caption'>some more captions</p></li>     </ul>   </div> </div> 

js:

$(document).ready(function() {     $('#homepage-images').flexslider({         animation: 'slide',         slideshowspeed: 3000,         controlscontainer: ".flex-container",     }); }); 

you've set li elements position: relative. use more specific selectors:

http://jsfiddle.net/isherwood/amdlp/2/

#homepage-images .slides li {     position: relative; } 

Comments

Popular posts from this blog

How to mention the localhost in android -

php - Calling a template part from a post -

c# - String.format() DateTime With Arabic culture -