Forums

Multi Language in ChronoFormsV4

fabroux 24 Feb, 2011
Hello,
I congratulate you for working with this release.
I just installed ChronoFormsV4 but I do not know how to make translations into three languages.

I added "Multi Language" in "On Load" after "show html" with:

"Language Tag" = en-GB
"Translation strings":
Contact contact =
...=...

How to add language es-ES fr-FR?
I tried to put another action "Multi-Language" in "On Load" but one language works.

And how to translate the "Show Message Thanks"?

Thank you all very much ...
(Sorry for my English, I'm French)
Max_admin 24 Feb, 2011
Hi Fabroux,

Glad you like itπŸ™‚

The multi language should usually be placed at the end of the event, on load or on submit, based on what you need to translate, it will translate the output of the action its placed into only.

for more than 1 language you need more than 1 multi lang action, each action for 1 language, the language strings will be used if the current website active language matches the tag.

Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
fabroux 25 Feb, 2011
Hi, Max and thank you

Here are some screenshots of my configuration.

Just last added language in the "on laod" works

That may be because of "Joom!fish?

Thank you
GreyHead 26 Feb, 2011
Hi fabroux and Max,

There is a bug in the current release which means that repeated actions are not handled correctly. Only the last is used.

The fix requires two changes.

In com_chronoforms/libraries/chronoform.php find the function _processAction() around line 128 and replace
$this->main_event_actions[$action] = $action_details;
with
$this->main_event_actions[] = $action_details;
and in com_chronoforms/chronoforms.html.php around line 23 replace
				foreach($form->main_event_actions as $action => $actiondata){
  $viewFile = JPATH_SITE.DS."administrator".DS."components".DS."com_chronoforms".DS.'form_actions'.DS.$action.DS.'cfaction_'.$action.'.ctp';
with
foreach($form->main_event_actions as $actiondata){
  $viewFile = JPATH_SITE.DS."administrator".DS."components".DS."com_chronoforms".DS.'form_actions'.DS.$actiondata->type.DS.'cfaction_'.$actiondata->type.'.ctp';

and, in the same file, around line 28 replace
require_once($viewFile);
with
require($viewFile);

Note: this seems to work OK but it may have side-effects that I haven't found.

Bob
fabroux 28 Feb, 2011
Hi GreyHead,

Before:
Only the final language of "on load" worked

With the modifications:
Only the first language of "on load" works

The solution must be near.
Thanks
GreyHead 28 Feb, 2011
Hi fabroux,

Hmmm . . at least something is different.

By all means email or PM me the site URL and a SuperAdmin login and I'll take a quick look. If that's possible if might be easier to diagnose than on my test site.

Bob
Max_admin 01 Mar, 2011
Hi,

Thanks Bob for the fix!πŸ™‚

It needs one more fix in the chronoforms.html.php file, instead of "require_once" please use "require" or contact me to send you the new file.

Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
GreyHead 01 Mar, 2011
Hi Max,

Excellent, I was just about to go and hunt for this :-)

I've updated my earlier post to include the extra change (and also the CFv4 bugs sticky post in this forum).

Bob
ivachok 22 Apr, 2011
Sorry for my English:) I'm from Ukraine. I have a problem: It is Joomla 1.5.23 installed ChronoForms v4 latest version, does not work multi language, when language is switched through joom! fish, in the form of language is not changed. Tell me what may be, may have learned to create multi language, where to find the problem? thank you!
GreyHead 23 Apr, 2011
Hi ivachok,

It's hard to tell from your image but the Input name 'navza' should not be translated. The Label and other text should be translated but I can't see that from here.

I don't currently have Joomfish installed to test :-(

Bob
This topic is locked and no more replies can be posted.