404 page when language code is in url eg. http://example.com/en

lckamal - 6 months ago

I have setup pyrocms in a demo server. when there is language in url it shows 404 page. http://almidan.go-demo.com/en

any idea?

ryanthompson - 5 months ago

What locales do you have enabled? Might have something to do with the hint being present AND the subdomain.. not sure though right now.

lckamal - 5 months ago

I have enabled en and ar. Is there something to be added in routes or htaccess for this? samething works on nginx but this is apache server.

ryanthompson - 5 months ago

Hard saying but this is where that stuff is taking place if you'd like to debug a little. I can help you if you can gather a bit more behavior / information about it: https://github.com/anomalylabs/streams-platform/blob/1.1/src/Http/Kernel.php#L84

lckamal - 5 months ago

It looks like none of the condition to define LOCALE is matched on Kernel.php. In my localhost it matched on this condition if (($hint === 'uri' || $hint === true) && preg_match($pattern, $uri, $matches)) { ... }

When I change $uri = $_SERVER['REQUEST_URI']; it works though