Hallo,
I use the HTML Macro to add some decent visualized object and JavaScript.
As I added Bootstrap script files
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.0/js/bootstrap.min.js"></script>
what makes the standard Confluence buttons not usable.
Any chance to limit the scope of the above-mentioned scripts to render only a dedicated section of my HTML?
I found Limiting scope of JavaScript source, could that be a solution?
I haven’t got it to work yet :( .
Hello there! That is an interesting question, Stefan.
I went ahead and tested this on a local instance running Confluence 6.14.2. Initially, adding only the script lines Confluence does indeed show problems.
The page tree does not work and there are no Space Tools for example.
However, when I add the following after both scrip lines there are no more problems:
<script> altjquery = $.noConflict(true); </script>
So, in the end you did find the correct solution for this! The HTML Macro content looks like this on my side:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.0/js/bootstrap.min.js"></script>
<script> altjquery = $.noConflict(true); </script>
Looking forward to your reply Stefan! Let us know your findings.
hey thx for your answer, will test that :).
I had the same discussion in a German forum and will add their code here but it isn't 100% clear for me yet but with your input, I'm optimistic to get all clarified and get it running!
stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for getting back Stefan!
Let us know if this works for you just like it worked for us. If you still have questions, come ask us!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.