Include macro doesn't work when special characters are used in the page title

When trying to include a page with special characters I get an error:

Unable to render {include} The included page could not be found.

For instance using the include macro to include a page titled: Special Character Test :"<>?,./;'[]{}!@#$%^&*()_+=-\][

will not render.

4 answers

Hi, An alternative to the standard include macro would be to use Reporting in this case. It may handle the special characters better. If you follow this link ( you'll see details of how to use report-info macro to pull back a specific excerpt, or indeed, the entire contents of a page. If this doesn't work then I'd suggest a user macro could achieve your goal, provided you pass the page ID to indicate the page you're interested in. Hope this helps, Charles

Doubled check on this and it seems to be a limitation of include page macro. However, the above suggestion might be possible.

This issue is resolved in Confluence 5.5:

Great news!

We ran into this problem, too, so I did as CharlesH mentioned and wrote a user macro to include a page based on the page ID. Maybe it will also be helpful for someone else who could not yet upgrade to 5.5.

## @param PageToInclude:title=Page ID of page to include|type=string|required=true
#set ( $Long = $generalUtil.getSystemStartupTime() )
#set ( $pageId = $Long.parseLong($paramPageToInclude) )
#set ( $page = $pageManager.getPage($pageId) )
#set ( $pageContent = "Page not Found" )
#set ( $pageContent = $page.getBodyAsString() )

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 ...

1,089 views 56 8
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