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
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published Thursday in Confluence

Three common content challenges + how to manage them

An efficient enterprise content management system, or ECM, is a must-have for companies that create work online (cough   cough, all companies). If content calendars, marketing plans, and bu...

89 views 0 6
Read article

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