Open davidsanz opened 8 years ago
I confirm it is a bug - I have the same issue on Symfony 3.1
Hi @davidsanz,
Did you by any chance for get the type: be_simple_i18n
in you route definition?
I've managed to replicate it with type: be_simple_i18n
set.
EDIT: looks like I forgot to add type: be_simple_i18n
to the parent routing file of the one where multilanguage prefix is defined. So it works for me on 3.1 Symfony :) Thanks @boekkooi
I dont know why but i've this error: Warning: trim() expects parameter 1 to be string, array given in C:\wamp\www\perieven\app/config\routing.yml (which is being imported from "C:\wamp\www\perieven\app/config/routing_dev.yml") with this routing file: expedientes:
resource: "@ExpedientesBundle/Resources/config/routing.yml"
type: be_simple_i18n
prefix:
es: /expedientes
en: /files
it: /cartella
de: /fahrzeug-unterlagen
fr: /archives
I guess app/config/routing.yml
itself isn't loaded as be_simple_i18n
type, so it throes an error. An easy workaround would be to have one more middle file in the routing files tree. Maybe there is a better way to define app/config/routing.yml
as be_simple_i18n
resource :bulb:
@davidsanz try in you app/config/config.yml
add:
framework:
router:
resource: "%kernel.root_dir%/config/routing.yml"
type: be_simple_i18n
Thanks aistis- but dont work. Return same error.
I've got the same error. Any updates on this issue?
You can solve that issue with changing routing_dev.yml;
//routing_dev.yml
.....
....
_main:
resource: routing.yml
type: be_simple_i18n
@anelad That fix makes your app_dev.php work, but production (app.php) won't work that way.
This issue wasn't there in beta1, only in 2.4.0.
Hello.
I use symfony 3.1 and if put prefix routing in app/config/routing like this:
got this error:
Warning: trim() expects parameter 1 to be string, array given in /Users/davidsanz/Documents/httpdocs/perieven/app/config/routing.yml (which is being imported from "/Users/davidsanz/Documents/httpdocs/perieven/app/config/routing_dev.yml").
Can help me please.
Thanks!