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

Problem with multiple domain website and SVG #40

Open
ghost opened this issue Jul 22, 2019 · 1 comment
Open

Problem with multiple domain website and SVG #40

ghost opened this issue Jul 22, 2019 · 1 comment

Comments

@ghost
Copy link

ghost commented Jul 22, 2019

Hello,

I encounter a problem with svg() command and multiple domain website.

I have a website in different language, and instead of using a prefix, I use different domain for different languages :

  • mywebsite.com (for english language)
  • mywebsite.fr (for french language)
  • mywebsite.de (for german language)
  • etc.....

my SVG loads correctly when I'm on the main domain (defined in app.url) mywebsite.com, but when I'm on the .fr or .de domain, SVG can't load cause the domain is not the same than the one defined in app configuration.

How can I bypass that and correctly display my SVG for all my languages ?

Thank you for your help

Best regards,

@tobias-kuendig
Copy link
Member

tobias-kuendig commented Jul 22, 2019

I guess the problem is caused by this line:

$appUrl = trim(config('app.url'), '/');

Maybe see what values you get. Is it possible that your .fr website still returns .com as app.url? You might be able to set these config values at runtime using a custom middleware.

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

No branches or pull requests

1 participant