Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Allow Flexslider inside bootstrap tabs

Status
Not open for further replies.

Carlvic

MIS
Jun 15, 2017
99
AE
Hello,

I have 2 slider for my page but my problem is when I insert my slider inside tabs is not showing

Here's my javascript and tried solution.


JavaScript:
/* Property details slider */
	$('#property-thumbs').flexslider({
    animation: "slide",
    controlNav: false,
    animationLoop: false,
    slideshow: false,
    itemWidth: 60,
    itemMargin: 10,
    asNavFor: '#property-images',            
	prevText: "",          
	nextText: ""
  });
   
  $('#property-images').flexslider({
    animation: "slide",
    controlNav: false,
    animationLoop: false,
    slideshow: true,
    sync: "#property-thumbs",            
	prevText: "",          
	nextText: ""
  });

  /* Property details slider2 */
 $('#secondary-property-thumbs').flexslider({
    animation: "slide",
    controlNav: false,
    animationLoop: false,
    slideshow: false,
    itemWidth: 60,
    itemMargin: 10,
    asNavFor: '#secondary-property-images',            
	prevText: "",          
	nextText: ""
  });
   


  $('#secondary-property-images').flexslider({
    animation: "slide",
    controlNav: false,
    animationLoop: false,
    slideshow: true,
    sync: "#secondary-property-thumbs",            
	prevText: "",          
	nextText: ""
  });


  /*ALLOW TABS*/ 
$(document).on('shown.bs.tab', 'a[data-target="#fplan"]', function (e) {
     $('#secondary-property-images').flexslider();
});



HTML


HTML:
<div class="tabs">
  <ul class="nav nav-tabs">
    <li class="active"> <a data-toggle="tab" href="#slider">{lang_media_slider}</a> </li>
    <li> <a data-toggle="tab" href="#fplans">{lang_media_plans} </a> </li> 
    <li> <a data-toggle="tab" href="#video">{lang_media_video} </a> </li>
    <li> <a data-toggle="tab" href="#360">{lang_media_360} </a> </li>

  </ul><!--nav tabs end-->
<!-- Tab Content-->
<div class="tab-content">

<div id="fplans" class="tab-pane">
<!-- FLOOR PLANS-->
<div class="property-slider2">

 <div id="secondary-property-images" class="flexslider">
                  <ul class="slides">
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                  </ul>
              </div>

                <div id="secondary-property-thumbs" class="flexslider">
                  <ul class="slides">
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                    <li class="item"> <img src="[URL unfurl="true"]http://placehold.it/600x400&amp;text=IMAGE+PLACEHOLDER"[/URL] alt=""> </li>
                  </ul>
                </div>
</div>
  </div><!-- Floor plan id end-->




Thankyou!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top