Skip to content

Instantly share code, notes, and snippets.

@Nav-Appaiya
Created August 7, 2023 18:45
Show Gist options
  • Save Nav-Appaiya/c25b578c3dcbaae9493c18cb0d414d4f to your computer and use it in GitHub Desktop.
Save Nav-Appaiya/c25b578c3dcbaae9493c18cb0d414d4f to your computer and use it in GitHub Desktop.
Link Owl Carousel
<div class="stone-slider owl-carousel">
<div class="item">
<div class="image"><img src="https://www.gettyimages.ie/gi-resources/images/Homepage/Hero/UK/CMS_Creative_164657191_Kingfisher.jpg" alt=""></div>
<a href="https://www.gettyimages.ie/gi-resources/images/Homepage/Hero/UK/CMS_Creative_164657191_Kingfisher.jpg">Click Image</a>
</div>
</div>
$('.stone-slider').owlCarousel({
loop:true,
margin:10,
nav:true,
autoplay: true,
rewind: true,
autoplayHoverPause: true,
autoplayTimeout: 7500,
autoplaySpeed: 3000,
items: 1
})
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/owl.carousel.min.js"></script>
a {
display: inline-block;
border: 1px solid;
padding: 10px 20px;
position: absolute;
bottom: 20px;
left: 20px;
}
a:hover {
text-decoration: none;
}
<link href="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/assets/owl.carousel.min.css" rel="stylesheet" />
<link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.1.2/css/bootstrap.min.css" rel="stylesheet" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment