[1.5.7] Multi language Approach

Hi there guys,

At the moment what would be the best approach to create multi-language sites in ContentBox.

/en/welcome
/es/bienvenidos
/fr/bienvenue

Do we need to install one instance per subfolder?
Or is it possible to manage all under the same administrator? (one instance)

Thanks in advance and for your always great tips

xerrano

One instance, just leverage the URL mappings for the language.

signature0.jpg

Luis F. Majano
CEO
Ortus Solutions, Corp
www.ortussolutions.com

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Social: twitter.com/lmajano facebook.com/lmajano

Thank you Luis as always,

Please let me know if this is what you mean:

by creating different “permalinks” as:

en/location

es/ubicacion

can this work?

Thanks

Well, that get’s more tricky but technically you can do things like this:

addRoute(pattern="/:lang{2}/location", handler=“myhandler.whatever");
addRoute(pattern="/:lang{2}/ubicacion", handler=“myhandler.whatever”);

signature0.jpg

Luis F. Majano
CEO
Ortus Solutions, Corp
www.ortussolutions.com

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Social: twitter.com/lmajano facebook.com/lmajano

No, I think he means to actually nest pages in the content hierarchy. So if you want english and spanish, create a page whose slug is “en” and a page whose slug is “es”. Then under those page, create two separate copies of your site. The URL would look like you put below, but you’re just drilling down into nested content.

We’d like to build better core support for multiple languages into ContentBox, but it hasn’t happened yet. We’d love to have a sponsor to help out the project :slight_smile:

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Thank you guys,

The way Luis mention it, I have been using something similar in Coldbox, but since for every page in ContentBox needs to be save into the database, I though I can have one site (one layout)
but creating every page using en/for_english and es/for_spanish (for small sites maybe can work)

Is valid to include the “/” as part of the slug of a page?

Hope some day can be more helpful to the CB community and be capable to sponsor a module or something… stay tuned :slight_smile:

Thanks again!

I create all my different language pages in one instance and assign them to an en, es or fr category just for organization. then i use the custom fields like so:

About (page):
key: en value: about
key: es value: acerca-de
key: fr value: a-propos-de

then, my dropdown looks like this:

Not sure why I added the url param lng, but it works great.

Hey Daniel,

Is it possible to give me an example of how you work with your approach for different languages content?
thanks…