Bootstrap Javascript does not work

1

I'm doing a page with Spring (JAVA) , and Bootstrap 4.0.0 . At first I had made the calls to the bootstrap files via web link, and everything worked perfectly. Now I want to change those calls to make them using the files locally, that is, I download the files of bootstrap . I call CSS locally and it works without problem, but when I call the files JS they do not work for me. The sentences I use are:

<link  href="<c:url value="/resources/bootstrap/js/bootstrap.min.js"/>"/> 
<link  href="<c:url value="/resources/bootstrap/js/bootstrap.bundle.min.js"/>" />

It should be clarified that the calls work, that is, if I see the compiled code and try to enter the JS file by the call, it takes me to the file, the problem is that the page does not respond as it should with JS . For example I have a alert with dismiss to close it and the button to close does not work, something that happens if I put the call back via web.

    
asked by Gastón 09.02.2018 в 16:46
source

1 answer

0

You must also include jquery in your file, which is why the javascript of Bootstrap is not working properly for you. You should always load the jquery library first and then load the ". Js" from the bootstrap as well:

<link  href="<c:url value="/resources/bootstrap/js/jquery.min.js"/>" />
<link  href="<c:url value="/resources/bootstrap/js/bootstrap.min.js"/>"/> 
<link  href="<c:url value="/resources/bootstrap/js/bootstrap.bundle.min.js"/>" />
    
answered by 09.02.2018 / 19:26
source