Problems with URL's in Diazo Theme

We have a new Plone 5 theme that we're using Diazo to pull html structures from an external server. Much of this structure has relative paths in the links. When viewed anonymously, the links work fine. When we log into the site, our URL changes from, for example, https://mba.smeal.psu.edu to https://secure.smeal.psu.edu/mba. After logging in, the links no longer work as expected as it strips off the /mba at the end, for example https://secure.smeal.psu.edu/some-page.

We have another Plone 5 Diazo theme, but the links are in the theme HTML itself and work as expected.

Any ideas why?

That one is tricky.
Just to be clear ...if you have an image located at https://mba.smeal.psu.edu/pic.jpg, after log in it becomes:
https://secure.smeal.psu.edu/mba/pic.jpg ?

Hi David, yes you are correct. Our plan was to house our navigation, etc on a file server then pull in via Diazo. Works fine on external, just not when logged in on different URL. It simply strips the trailing "MBA" in this case, resulting in a bad URL.

Sounds like the easiest solution is to get your server admins to not have it as subfolder. I'm sure there's a way to do it in Diazo but it would require detecting the URL.

Try setting the Absolute path prefix.
Set it under Theming controlpanel > Advanced settings > Theme details > Absolute path prefix

@cthomas,
Here's how I was able to serve theme resources from a "CDN", firebase in this case. This is for the Python Jamaica website.

  1. Load theme resources to firebase
  2. Also load theme resources in the theme
  3. In the theme manifest.cfg add this line
rules = /++theme++pythonjam2017/rules.xml
prefix = https://pythonjamaica2017.firebaseapp.com

(note that the rules are served locally and the CDN is defined in the manifest.cfg)

This setup forces resources to be served from the prefixed location.
You will most likely need to reinstall the theme for it to re-read the manifest.

Thanks for all the suggestions. I may be wrong, but I think your case is housing the theme itself externally, including, but not limited to the rules files, etc. We are not. All we're trying to do is house and serve, some html, CSS and JS on an external server and bring it in. Our rules.xml, etc resides on the Plone site itself. All things work, on either URL I mentioned, except for the relative links in the html. On the logged in URL, https://secure.smeal.psu.edu/mba, the links dont work as Diazo, for whatever reason, drops the /mba at the end, and tacks on the page/folder path.

I believe there is a solution with pure XSLT that we may try, but at this point, its a bit "above my pay grade".