0

When trying to find a slider to display my products on frontpage i found a lot out there. But no of them could make a slider in list view.

What I am looking for is something like this enter image description here

I want to make 3 produkt with a width of 100%. then slide to se 3 new. Can someone help?

1

Use owl carousel slider

Add below code in homepage

{{block type="core/template" name="homepage-slide" template="yourtemplate/yourtemplate.phtml"}}

Your below code to template yourtemplate/yourtemplate.phtml:

  <div id="owl-demo">
    <?php i=1; foreach($collection as $child){ ?>
      <?php if($i == 0 || $i%3 == 0) { ?>
        <div class="item">
          <ul> 
      <?php } ?>
            <li>Product code here</li>               
      <?php $i++; if($i%3 == 0) { ?>
           </ul>
          </div>
      <?php } ?>
   <?php  } ?>    
    </div>

javascript code:

$(document).ready(function() {

  $("#owl-demo").owlCarousel({

      autoPlay: 3000, //Set AutoPlay to 3 seconds

      items : 4,
      itemsDesktop : [1199,3],
      itemsDesktopSmall : [979,3]

  });

});

It helpful to you

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.