Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Relative path vs full path for images and PDF links
#26
Thanks Carlos.

I personally am totally fine with such workarounds, I only have problems giving such solutions to customers. I will soon create my first commercial site with GS, and me and the customer will both have a local installation as well as a hidden online site for testing in some subfolder, plus the live site.

A dynamic URL would work no matter what, but all search and replace solutions will always need some fiddling.
So I still hope this can be solved at the root one day.

ModX uses a "base URL" in the page header like this:
<base href="http://www.Sitename.com/MaybeSomeSubfolder/" />
And then all URLs are relative to that. Dead simple.
The only thing needed would be a modification to the filebrowser so it writes relative URLs or a plugin that strips the base URL from everything the browser delivers right at the moment it's written, so it's transparent to the user. And the Content Editor would have to be aware of that.
Since it's not relative to the page but relative to this base URL, no tracking of changes in hierarchy is needed.
The Base URL is what's entered in the Settings page of GS, so each installation can simply have an individual base.

I don't know what the hurdles are for such a solution or if there are any drawbacks.
I never had any issues in ModX.

Cheers,

Tom
Reply


Messages In This Thread
RE: Relative path vs full path for images and PDF links - by Thomas Helzle - 2013-08-17, 23:50:05



Users browsing this thread: 1 Guest(s)