[opencms-dev] Absolute links to different webapps in same server as site root gets changed to relative links
Nacho Fernández
jifernandez at ugr.es
Tue Jul 21 13:35:05 CEST 2026
Hi all,
Haven't found a solution looking up similar problems in the mailing list
archive, so I'll try to shout out my problem:
I have an OpenCms installation residing in a web server (let's call it
https://myserver) with OpenCms itselft not as root webapp but deployed
as /portal
The url https://myserver it set as "site root". Whenever I try to create
an absolute link to a different webapp inside my server, which I need to
do quite often, be it with the inline editor or directly editting the
control code, OpenCms changes it automatically to a relative link
pointing inside https://myserver/portal, ruining the link in the
process. For instance, if my webapp is called "mywebapp" and I want an
absolute link https://myserver/mywebapp/whatever it gets changed inside
the control code to a relative link to /sites/default/mywebapp/whatever
which translates when I want to click it
into https://myserver/portal/mywebapp/whatever
Is there anyway to configure out this annoying behaviour? Can I just
simply not list my actual server as the "site root", as I assume it is
what OpenCms is using, without breaking anything important such as
access to the workplace or static export? I already tried listing the
site root as "http://myserver" (the not secure alternative) and it keeps
behaving exactly the same.
I would be REALLY grateful if I could get some hints from anyone. Thank
you in advance,
Nacho Fdez.
More information about the opencms-dev
mailing list