How to inject macro html in editor

Modules are shown as "box" in the editor and converted into HTML at run time.

I'd like to know if it is possible to inject the HTML code directly to the editor so that we can edit it right away. It would be like small templates we can add where we want in the page being edited.

For instance, we have some documents which contain many table with the same format (same headers, same lines) and instead of copy/past i'd like to add a button or macro to add it dynamically at the cursor position. Then the user would fill in the blank cell with some text.



1 answer

It should be possible to extend the editor JavaScript, but I think you will habe to die yourself through the JavaScript oft the editor Plugin...

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Friday in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

274 views 11 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you