Skip to content
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

Closed
wants to merge 1 commit into from

Conversation

bloveless
Copy link
Member

@RyanThompson would you take a look at this and pull it if it seems to make sense to you.

@RyanThompson
Copy link
Member

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.

@bloveless
Copy link
Member Author

Alright! That's why I was checking. I'll go the long way around.

@bschmitt
Copy link

+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.

@bschmitt
Copy link

Sorry, I just saw this is only for the backend. But it's always good to keep that in mind.
Regarding the other PRs hope that's not Frontend related.

@RyanThompson
Copy link
Member

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.

On Dec 14, 2015, at 3:40 PM, Björn Schmitt notifications@github.com wrote:

+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.


Reply to this email directly or view it on GitHub #3584 (comment).

@RyanThompson
Copy link
Member

No it was CP only. I think I might move this idea into the image / asset class for 3.0 though.

On Dec 14, 2015, at 3:44 PM, Björn Schmitt notifications@github.com wrote:

Sorry, I just saw this is only for the backend. But it's always good to keep that in mind.
Regarding the other PRs hope that's not Frontend related.


Reply to this email directly or view it on GitHub #3584 (comment).

@bloveless
Copy link
Member Author

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 RyanThompson deleted the 2.2/make-wysiwyg-more-versatile branch March 2, 2017 15:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants