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 Oct 24, 2018 in Confluence

Atlassian Research opportunity with Confluence templates

Do you use templates with Confluence? Take part in a remote 1-hr workshop. You'll receive USD $100 for your time!   We're looking for people to participate in a   remote 1-hr workshop...

1,147 views 20 14
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