jquery conflict
Permalink
Hi, I saw a piece of code to solve the js conflict, but I don't get how to make it work. When I put it I do not have any more issues when editing a page , but I have issues on the front end with jquery not working anymore ... I actually never really understood how to handle those jquery/css conflicts, I would appreciate some link to an easy to understand tutorial .... many thanks
Here is the code I found
And here is my original code, in case someone would be kind enough to help me find out how I should be placing this code
Here is the code I found
<script src="<?= $view->getThemePath() ?>/js/bootstrap.js"></script> <script>var $j = jQuery.noConflict(true);</script> <script> $(document).ready(function(){ console.log($j().jquery); // This prints Bootstrap's jQuery }); </script>
And here is my original code, in case someone would be kind enough to help me find out how I should be placing this code
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script> <script src="<?= $view->getThemePath() ?>/js/bootstrap.js"></script> <script src="http://cdnjs.cloudflare.com/ajax/libs/bootstrap-datepicker/1.3.0/js/bootstrap-datepicker.min.js"></script> <script src="<?= $view->getThemePath() ?>/js/custom.js"></script> <script src="http://localhost:35729/livereload.js"></script> </div> <?php Loader::element('footer_required') ?> </body>