Hello there!
I have an html macro. Inside, there is a section tag followed by a script tag with some javascript to prompt a dialog box upon some trigger. Within the section tag I was hoping to reference the span macro created outside of the html macro. This span holds tabulated data whose rows are automated by Confluence as opposed to manually entering each via html syntax. The objective is to show a dialog box upon opening the page containing a question and this table. Thank you! This is my first post, so please advise if there is a better way to structure my problem.
Hello Carissa,
Welcome to Atlassian Community, and thanks for raising this with us. It looks like you might be using a 3rd-party add-on to add the HTML and span macros since they're generally not supported in Confluence Cloud.
Can you let me know the name of the add-on you're using to make sure we give you the correct information?
Thank you!
Shannon
Hi Shannon,
Sorry, I am pretty new to Confluence. By "add-on", do you mean the macro name? This is what I selected. Thank you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Carissa,
Thank you for the screenshot. That macro you circled looks like one we had in Confluence Cloud a few years ago but discontinued. The other macros with an orange icon (including the Span macro you're using) are by a third-party provider.
To answer your original question, I don't think it's possible to reference another macro from an HTML macro, but we'll need to confirm what version of that macro you're using to know for sure.
Can you confirm with me your Confluence version and that you are writing us about a Confluence Cloud instance and not a self-hosted server site?
Thank you!
Shannon
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shannon, thanks for that information! How can I find which Confluence version I am using? It is likely that my company is using a self-hosted server site. If that is the case, what are the limits in terms of the HTML macro I am trying to use? And would there be an alternative? Thank you so much for your time and patience!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Oh, sorry, the version we are using is Atlassian Confluence 7.10.2. Not sure if that was what you were asking for.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Carissa,
Thank you for clarifying. That is precisely what I needed.
According to our HTML macro documentation, I don't see a documented way to reference other macros. While the HTML macro is ours, that particular span macro you're trying to reference is 3rd party macro. You might want to contact the vendor and see if they have any suggestions for you.
I found a few other threads that might give you some leads:
Some suggestions are to use User Macros instead. If you still have trouble, you might even want to try Atlassian Developer Community. Your question is high-level so that you may find better success there.
I hope that helps!
Take care,
Shannon
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shannon,
How do I filter out User Macros? Additionally, how will I know whether the macro is from a third-party?
Happy Learning!
Carissa
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Carissa,
We have a list that you can compare if you want to know if a macro came with Confluence or if your team installed it:
User Macros are a feature we included with the Server and Data Center versions of Confluence. It provides a way for your team to create custom macros. You supply the name for these macros, and you can add them like you would any other macro by typing its name.
I found a blog post that might help clarify things. We didn't write it at Atlassian, but I still find it very helpful.
Confluence User Macros - An Introduction
I hope that helps! :)
Take care,
Shannon
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.