How to make Bootstrap carousel slider use mobile left/right swipe


I came up with this solution when I was pretty new to web design. Now that I am older and wiser, the answer Liam gave seems to be a better option. See the next top answer; it is a more productive solution.

I worked on a project recently and this example worked perfectly. I am giving you the link below.

First you have to add jQuery mobile:

This adds the touch functionality, and then you just have to make events such as swipe:

$(document).ready(function() {
   $("#myCarousel").swiperight(function() {
   $("#myCarousel").swipeleft(function() {

The link is below, where you can find the tutorial I used:

Leave a Comment