You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The main site should have a domain associated with it.
The specific use case I have right now is for absolute URLs in emails - subsites have domains associated with them so calls to AbsoluteLink result in the appropriate URL for any pages belonging to a subsite - but for main site absolute URLs (especially when using a queued job via the cli where there is no host to draw from) I have to work around it by storing the domain somewhere effectively arbitrary.
If the main site had a domain the same way that subsites do, getting an absolute URL for the main site would be straight forward.
(for the absolute URL to automatically apply correctly in an email, we'd need to make a change to Director::absoluteURL (see silverstripe/silverstripe-framework#10168) - that is obviously out of scope for this issue, which is dealing with getting a correct absolute URL when using AbsoluteLink on a page which I am currently doing to set absolute URLs prior to setting the email body)
The text was updated successfully, but these errors were encountered:
Also noticed possibly the same issue when on a subsite, editing pages inside the CMS. Select the "Main site" and the page UrlSegment fields still point to the subsite domain, presumably because it doesn't know the main site URL.
@GuySartorelli thanks for looking at it, the issue is not the opened page appearing on the wrong site. It's the correct subsite (main site), correct page, wrong domain in the UrlSegment field.
Oh, weird. Okay. That should probably be raised as a separate issue then, if you don't mind. That shouldn't be happening at all, regardless of whether the main site has an explicit domain.
Can you please create a new issue detailing the bug with step-by-step instructions for reproducing it from a fresh installation?
The main site should have a domain associated with it.
The specific use case I have right now is for absolute URLs in emails - subsites have domains associated with them so calls to
AbsoluteLink
result in the appropriate URL for any pages belonging to a subsite - but for main site absolute URLs (especially when using a queued job via the cli where there is no host to draw from) I have to work around it by storing the domain somewhere effectively arbitrary.If the main site had a domain the same way that subsites do, getting an absolute URL for the main site would be straight forward.
(for the absolute URL to automatically apply correctly in an email, we'd need to make a change to
Director::absoluteURL
(see silverstripe/silverstripe-framework#10168) - that is obviously out of scope for this issue, which is dealing with getting a correct absolute URL when usingAbsoluteLink
on a page which I am currently doing to set absolute URLs prior to setting the email body)The text was updated successfully, but these errors were encountered: