Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Multiple Domain Names pointing to same GS installation
#11
Thanks @Alexander, but I don't think your solution preserves the domain in the url line.
Update on what I did:
(Problem: allowing multiple sites to access the same GS hosting, preserving the referring site's domain name in the url line)
It turns out that GetSimple 3.3.13 does seem to accept relative links of the form ./slug or slug (assuming permalink expansion %slug% without %parent(s)%)
This also makes it possible to move a site to another location by just copying the entire site, (and editing the website url in the settings).
I have a proxy redirect from another hosting (where I can't introduce my own url rewrites). It points to a subdirectory in the main site, with prefix /GS/.
I wrote a component which patches urls so they become relative (mySiteUrl) and which contains a kludge that removes the /GS prefix when necessary.
The trouble with relative addresses is that CKEditor doesn't even see them (and it always reverts to an absolute address when switching from html source view to WYSIWYG mode), so they must be inserted using the html source view.
Anyway, I can make relative links work for me (both for slugs and data/uploads/ paths as for "img src=") and I can make links relative using my component (EXCEPT when I include the component using dynpages in a html source construct like <a href="{%mysiteurl%}slug">linktext</a> -- that doesn't seem to expand the prefix **reliably**: it must have something to do with execution order of the GS engine)

It further turns out that some plugins generate absolute addresses (taken from the path in the settings), such as the i18n nav menu by mvlcek. Luckily for this case a custom component can provided to implement the menu link rendering (which I did to convert his absolute links to relative). But for other plugins, such as the i18n searchform there is no custom rendering option, so that won't work.
Sorry to say, but this reliance of GS on absolute addresses with a prefix as defined in the settings, is rather frustrating. I hope GS 3.4 will address this concern.  (I know there is a thread on that topic, but I wonder if there is already a final solution that could be applied to 3.3.13 e.g., by patching gsconfig.php)

Am I making things too complicated? Any suggestions?
Reply


Messages In This Thread
RE: Multiple Domain Names pointing to same GS installation - by vanfruniken - 2017-08-03, 21:01:23



Users browsing this thread: 1 Guest(s)