spatie/laravel-missing-page-redirector

does this work with subdomains (if a wildcard domain is already setup)

vesper8 opened this issue · 1 comments

I run a video gaming website and I had previously set it up so that each game had its own subdomain. But now I've decided, for many reasons, to switch to having a single subdomain (www)

so I want to redirect things like this

mass-effect.mydomain.com/someId -> mydomain.com/mass-effect/someId

Would something like this work out of the box

'redirects' => [
   '{game}.mydomain.com/{id}' => 'mydomain.com/{game}/{id}',
],

I imagine this won't work because your package doesn't do anything at the domain level?

Just wondering if a custom redirector would work or if your package is just not suited to handle my scenario?

Thanks!

If memory server me right, the redirector does not take the (sub)domain name into account.