Multi Language Support

Get help with installation and running phpwcms here. Please do not post bug reports or feature requests here.
User avatar
Jensensen
Posts: 3000
Joined: Tue 17. Oct 2006, 21:11
Location: auf der mlauer

Re: Multi Language Support

Post by Jensensen »

mmartin wrote:...How do I activate the scrip - it is in the template\inc_script\frontend_render\disabled\ folder - certainly it is not used there. Do I have to include it somewhere...
to activate FE render scripts just place/copy/ move them one directory up to
template/inc_script/frontend_render
{so_much} | Knick-Knack. | GitHub
Umlaute im URL sind meistens immer Kacke.
Peekay
Posts: 286
Joined: Sun 25. Jul 2004, 23:24
Location: UK

Re: Multi Language Support

Post by Peekay »

If I understand marcuses multi-language solution correctly, both language versions of each page are present on the site as separate pages, rather than being generated dynamically based on a language choice.

I can see that attaching a custom settings file to each template will overide the date format settings, but in order for Google to find and index (for example) both English and German content pages, wouldn't it be necessary to identify the German pages as being in the German language, i.e. by changing the 'lang' value for the HTML tag of the template used in that structure, e.g.

<html lang="de">

I figure that doing that would enable those pages to be listed by any search engine when 'de' was sent in the Accept-Language request-header?
ShyGuy
Posts: 158
Joined: Sat 11. Nov 2006, 15:27
Location: DE-Hannover
Contact:

Re: Multi Language Support

Post by ShyGuy »

I did a multi language site by having an additional installation of the site, each in its own folder. The folders get assigned to a sub domain where I switch between them using a small PHP-Script.
This gives page-by-page possibilities, absolutely painless.
One of the main advantages -for me- was the easier maintenance of each language where I can modify the templates to specific needs (read more », plus de détails », más información ») and much more important to me:
I like the idea of having each language separated from the other. By doing it so, I
- have a single (!) tree of articles for each language - where I'm no longer confused where I currently perform changes.
- can give the translation process to an other person without being afraid that other language content gets destroyed wrongly.
- can make a new copy of a language is as simple as copying a folder and a database; perfect for testing an update in a backup first or to try something completely new...

Example given: We got a French translation.
I made a copy of the EN folder and the EN database (took me 3-5 Minutes). Changed the database in the conf.inc.php and assigned a temporary sub domain to this new folder.
The person who made the translation had a running -but not public- system instantly. After everything has been checked, I just changed the sub domain to 'FR' and inserted the links to the French version.
Sounds not perfect to me; but it's a good choice when considering the narrow possibilities of WCMS...

I tried to explain what I did here http://forum.phpwcms.org/viewtopic.php?f=10&t=17447
And you can see how it works here: http://www.xecro.com
Peekay
Posts: 286
Joined: Sun 25. Jul 2004, 23:24
Location: UK

Re: Multi Language Support

Post by Peekay »

Thx for that example. :) Works very well.

I can see that your French version contains the meta

Code: Select all

<meta name="language" content="fr" />
but I would be interested to know if you have found that addition sufficient to get your French pages listed for French users if they search for key phrases (in French) in a search engine?.

Custom page metas (like language) can be added at template level in PHPWCMS, but I am still guessing that appending the 'lang' value to the HTML tag would carry greater weight.
User avatar
Oliver Georgi
Site Admin
Posts: 9892
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: Multi Language Support

Post by Oliver Georgi »

I will introduce option to inject html by lang params.

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
User avatar
Oliver Georgi
Site Admin
Posts: 9892
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: Multi Language Support

Post by Oliver Georgi »

Ok, have a look at r239

<html> Tag enhanced by language attributes. You can inject the doctype language
by changing $phpwcms['DOCTYPE_LANG'] to your preferred value (use frontend_render
or frontend_init to inject it). By default the same language as defined in
$phpwcms['default_lang'] is taken.

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
ShyGuy
Posts: 158
Joined: Sat 11. Nov 2006, 15:27
Location: DE-Hannover
Contact:

Re: Multi Language Support

Post by ShyGuy »

>Peekay

to be honest; I haven't thought about that so much. The first I wanted to do is getting my site running and available in different languages...
I have the others (de, fr, es) since two weeks, so I need to wait until the crawler comes again to visit the site. Then I can examine if it was enough or if I need to spend some extra effort. :idea:
Peekay
Posts: 286
Joined: Sun 25. Jul 2004, 23:24
Location: UK

Re: Multi Language Support

Post by Peekay »

<html> Tag enhanced by language attributes...
Many thx Oliver. That is an excellent addition IMHO. :D
ShyGuy
Posts: 158
Joined: Sat 11. Nov 2006, 15:27
Location: DE-Hannover
Contact:

Re: Multi Language Support

Post by ShyGuy »

Kann ich bei der Verwendung von [EN]text[/EN] eigentlich verhindern, dass die Backend-Ansicht in der Artikelzentrale und Seitenstruktur ebenfalls alle Sprachen anzeigt ?
Im Moment habe ich in Seitenebene Überschrift: [EN] relativ langer Text[/EN][DE]relativ langer Text[/DE][ES]...
stehen, und das gleiche dann auch mit diversen Zeilenumbrüchen in besagten Listen :(

Hier wäre ein Filter auf eine bevorzugte Sprache wirklich prima !


In der Hoffnung, etwas übersehen zu haben,

Stefan
User avatar
marcus@localhorst
Posts: 815
Joined: Fri 28. May 2004, 11:31
Location: localhorst
Contact:

Re: Multi Language Support

Post by marcus@localhorst »

hast leider nix übersehen, text ist text und das backend kümmert sich nicht um die replacementtags vom frontend.
Das ist eben der Pferdefuss mit dieser Art der Mehrsprachenverwaltung...

Das Einzige dies zu umgehen, wäre evt die Mehrsprachenunterstützung auf Basis der @@Text@@ Tags für Überschriften:
http://code.google.com/p/phpwcms/source/detail?r=302
http://www.phpwcms-howto.de/wiki/doku.p ... ltilingual

Meint, die deutschen Überschriften kommen zwischen die @@ Zeichen. dann musst du allerdings die Übersetzungen in der entsprechenden Datei nachtragen.
Das ist allerdings nix, wenn sich die Inhalte der Seite ab und zu ändern.
Also vergiss es lieber wieder ;-)

Grüße
m.
ShyGuy
Posts: 158
Joined: Sat 11. Nov 2006, 15:27
Location: DE-Hannover
Contact:

Re: Multi Language Support

Post by ShyGuy »

Danke Marcus,

ich hatte gedacht, dass es nur konsequent gewesen wäre in der conf.inc.php eine Sprache für einen Backend-Filter zu definieren - aber lieber die Gewissheit, dass dem nicht so ist, als ständig auf der Suche zu sein.

Stefan
User avatar
Oliver Georgi
Site Admin
Posts: 9892
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: Multi Language Support

Post by Oliver Georgi »

Dann müsste das Backend erweitert werden. Möglich wäre der Filter auch dort.
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
ShyGuy
Posts: 158
Joined: Sat 11. Nov 2006, 15:27
Location: DE-Hannover
Contact:

Re: Multi Language Support

Post by ShyGuy »

Die Sprache kann dann evtl. besser in den Benutzereinstellungen, als in der config.in.php angeben; so denn die Filterung im Backend der nächste logische Schritt für die Multi-Language-Umsetzung wäre. Ich würde einen Filter im Backend sehr begrüßen !
mark@magicomm
Posts: 7
Joined: Wed 27. Jan 2010, 00:17

Re: Multi Language Support

Post by mark@magicomm »

I am new to this forum, so forgive me if I ask something that's already answered (or something stupid which is also possible) :oops:
We have a client who wants to take their phpwcms site into multiple language. They want separate sites for each, so they can locally manage the content on a country by country basis. I am thinking the best solution is the process described by ShyGuy.

So two questions:
1. Has there been any changes that we should consider which would suggest a different approach?
2. Anyone interested in being paid to do this work? I have almost zero experience in phpwcms and our previous developer is now gone. Or can you suggest someone to contact that might be interested in this job? Does not seem to complex, but I can't afford to spend the time to learn it all, just for this one change. Likely smarter to pay someone who can do it in 1/4 the amount of time.
Let me know.
Thanks
User avatar
juergen
Moderator
Posts: 4556
Joined: Mon 10. Jan 2005, 18:10
Location: Weinheim
Contact:

Re: Multi Language Support

Post by juergen »

So -requesting if this might be worth to follow -

I do have a running solution in 2 Languages article based switching, which means 2 trees (or even more) and absolutely free designed URLs, based on a additional "Language switch Table".

Sorry to have no LIVE Example for all, but one by PN ;)

Jürgen
Post Reply