Ad

Jquery Not Functioning In Bootstrap Template

- 1 answer

I've using bootstrap template for my project https://almsaeedstudio.com/. I've also add i few jquery script but it not working.

I've have tried to use this method but also not working. i can't use javascript code with bootstrap template

This is my html:

<button type="button" class="btn btn-primary btn-lg" id="view-more">Large</button>

This is my jquery code:

<script src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>

<script>
var $j = jQuery.noConflict();
$j(document).ready(function(){
    $("#view-more").click(function(){
        alert("Test");
});
</script>
Ad

Answer

You have missed the closing });

var $j = jQuery.noConflict();
$j(document).ready(function(){
    $("#view-more").click(function(){
        alert("Test");
    });
});
Ad
source: stackoverflow.com
Ad