Reusable domain in links

How (if at all possible) can I create links with reusable (like "excerpt-include") domain? 

I'm writing technical documentation where in multiple pages there should be a link to an external resource. For every page the resource is different but the domain  part of the link is the same. The problem is that domain is a subject to change and in the case of change I don't want to go through hundreds of pages and edit the link.

I imagine it should look something like that: [{excerpt-include:_commonDomain|noframe=true}/some/resource]. This of course does not work for obvious reasons.

Am I missing something obvious or is this not possible to achieve atm?

1 answer

I'm not sure it would work for you, but I wrote a user macro to do a global search and replace, so if you are changing domains then it would be able to update it on every single page.  Unfortunately, it would also show you as editing 100's of pages at a time, but maybe it would be easier than trying to extract a domain from somewhere else, as you could just use the standard Confluence functions.  You can find the user macro here:

Just embed it in a blank page and you will be all set to go.

Thank you for your suggestion. I've saved the script and will try it out when domain changes. It's a little bit sad that there is no simpler way though.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Feb 06, 2019 in Confluence

Try out the new editing experience

Hi team, I’m Avinoam, a product manager on Confluence Cloud, and today I’m really excited to let the Community know that all customers can now try out the new editing experience and see some of the ...

783 views 33 5
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