-
Notifications
You must be signed in to change notification settings - Fork 935
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make wysiwyg more versatile by using an absolute URL without a BASE_URL #3584
Conversation
This will break on some applications. I've just recently pulled in a handful of PRs on 3.0 doing the opposite of this. Personally, wouldn't affect me but it does others. |
Alright! That's why I was checking. I'll go the long way around. |
+1 It's a bad design approach to use TLDs in paths. Having absolute paths solves many issues regarding the use of cache proxies (like varnish) when it comes to caching of HTTP vs. HTTPS page variants, search indexing and having multiple production, staging and development servers. I cannot even think of a reason why this will break other applications? The only reason for having a (sub-) domain used in paths is when you want to serve the assets from a CDN provider or a different domain to increase the amount of simultaneously requested files by a browser. |
Sorry, I just saw this is only for the backend. But it's always good to keep that in mind. |
TBH this is where I sit with it. When we visited it before it was primarily a dev thing I suppose. I think we should pry reopen this discussion cause I’ve been thinking about it a bit too. I have never / will never run into issues with this and I suppose if it’s only dev environments that will (not using a local host).. I can live with that. Thoughts? Not like we can’t add a TLD if necessary.
|
No it was CP only. I think I might move this idea into the image / asset class for 3.0 though.
|
My issue is that we are running our admin through a different URL than the site runs off. I've probably done something differently than most, but here is my little demonstration. We are using Amazon CloudFront as a CDN. We had to update our server to run off www-origin rather than www so that cloudfront could have www. This makes the server think it's domain name is www-origin rather than www and it breaks all of our URL's. So I changed the BASE_URL to point to www but we have to access the admin from www-origin. So there is a discrepancy between the front-end and back-end of the site. Though I could see people who are severely paranoid about security using a different subdomain for their admin (I.E. cms.example.com) Also I looked through the HTML coming out of the admin and these wysiwyg javascript links are the only one that prepends BASE_URL to be in front of them. |
@RyanThompson would you take a look at this and pull it if it seems to make sense to you.