After Adding a Context Path to the Base URL, Icons Appear as Broken Images
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
After adding a context path to the Base URL, icons appear as broken images.
Diagnosis
Environment
- Confluence 5.10 or above (including Confluence 6.x)
- The Base URL was changed with an added context path. For example, the Base URL was
- http://confluence.mycompany.com/
- http://confluence.mycompany.com/confluence
Cause
The context path needs to be changed in both server.xml
and confluence.cfg.xml
. This is new since Confluence 5.10.
Resolution
To fix this, look at <confluence-install>/conf/server.xml
and check the path
attribute in the <Context />
element, here path="/confluence"
.
<Context path="/confluence" docBase="../confluence" debug="0" reloadable="false" useHttpOnly="true">
edit <confluence-home>/confluence.cfg.xml
and change confluence.webapp.context.path
from
<property name="confluence.webapp.context.path"></property>
to
<property name="confluence.webapp.context.path">/confluence</property>
Please review the documentation here