dropdown or cascadedropdown select diferent lists

javier94

Member
i'm usign jomla 3.8.3 and fabrik 3.8

i have check some post and elements guide but i don?t know the best way to do it..

i have seen dropdown and cascade dropdown

What i need is:

I have right now a element dropdown as Language selection of : English, Spanish, Catala, French, etc...

and i have one form and one list for each language.. list english
list spanish
list catala
list french


How i can related.. ??


i would like ... once you select the language in the selection dropdown for example english... will appear next ....the list for the language selected.. in the same page.. if a change in the dropdown for other language.. will appear next the other list language.

thanks in advance...
 
No, you can't have a CDD which uses different tables.

What are you actually trying to achieve? Typically for multi languages you would use a single table, with either multiple fields for the different laguage values, named for the short language code (en, fa, de, etc) and use {langtag} as a placeholder in a join's "CONCAT" tab, or have multiple rows, with the language ID as an FK, and use a CDD.

-- hugh
 
So the multi laguage table would either look like ...

id, en, fa, de
1, English name for Thing 1, Farsi name for Thing 1, German name for Thing 1

... and have a join to it which uses {shortlang} as the CONCAT label, or ...

... or ...

id, lang, name
1, en, English Name for Thing 1
2, fa, Farsi name for Thing 1
3, de, German name for Thing 1

... and use 'lang' as the FK on a CDD which watches a join to the J! language table

-- hugh
 
Of course another way is to use actual language strings, like THING_1_NAME instead of regular strings in your table, and add language overrides in J!. Fabrik runs pretty much everything it displays from elements through the J! JText API.

-- hugh
 
well. thanks for your reply..

but if i follow your explanations.. i have to create everything new.. and my previous work will have no sense.

I would like to comment you other option to profit my previous work..

i have a curriculum vitae for a candidate in one language almost finish.. so for the rest of languages "eng" for example.. my previous idea.. would be... copy the same list... change the labels to "english" or other languages.. and "SAVE" in the same table all the languages.... doing that i understand.. all the languages will save in the same table...

we can make a previous step... with only one element .. dropdown.. selecting language.. where the candidate...

select language "1" .. and click in a button for example ... go to list language "1"
select language "2".. and click in a button for example ... go to list language "2"
etc.....

how i can make the dropdown and button to do that..???

thanks in advance

-- Javier
 
I'm not really understanding what you are trying to do.

Can you take a step back, and describe your application and the workflow. If necessary, write it in both English and in your native language, and I'll use Google translate.

-- hugh
 
hello..
we are making a curriculum vitae form
https://www.selectiumlab.com/index.php/ca/resultats

as you will see..there is list of a curriculum in Catalan language..
the first element.. is a language selector... and the idea was changing the language.. change the list.. in other language.. ( and you explained how to make.. in the same table etc..)
this option will be in one page..


as i dont want to lose this work.. i though about and may be we can make in 2 pages.. instead of one..

Can we make a list with only ONE ELEMENT... ( the language dropdown) + a button or other thing.. and when we select the language a click to the button --> change to the 2 page and the 2 page show the LIST in the language selected..???

thanks

Javier
 
So are you trying to make it such that the labels on the elements display in the selected language?

-- hugh
 
i think that the same thing, we can make in diferent ways..

1 option = would be ......the labels on the element display in the selected language... ( as you ask to me)
2 option = would be ...... make in one page a dropdown with the language selector, and once you select the language and if you put a button for exxample and click the button.. open a new page.. with the list of this language..

i have make the LIST in the five languages.. so maybe the option 2 would be better o less work..

thanks

Javier
 
It might be less work in the short term, but having to maintain 5 separate lists/forms will be a big headache for long term maintainability. And if you add a new language, then you have to go back and add another list, and modify your setup.

So before I help you do it any other way, I'll have one last go at convincing you to do it "the right way". Joomla is designed for multiple languages, and Fabrik goes to great lengths to run pretty much everything through the J! translation.

https://docs.joomla.org/J3.x:Setup_a_Multilingual_Site

If you want to support different languages, the best way is to set up a multilingual site, that lets the user choose their language. Then all you have to do to make your Fabrik forms multilingual is use language tags in places like element labels, and add language overrides for them in J!'s language manager. As long as the language isn't too esoteric, Joomla and Fabrik will already have translations for that language, so not only the strings you provide (for labels, dropdown options, etc) get translated, but all the hard coded language (like button names, error messages, etc) get translated.

Yes, setting up a multilingual site is more effort to start with, but it's the much better solution (the user can use the whole site in their native language, not just that one form), it leverages the decade or more of effort in the J! and Fabrik communities to make J! multilingual, and in the long run the maintenance is vastly simpler - all you have to do is maintain your custom language tags.

-- hugh
 
ok.. i'm gonna try to make each label element in the appropiate language.. to change the labels... using joomla

i have found how to change the dropdown element etc.. but i have not found how to change for example a display element... when display element have a code..

attached picture
Captura-label-2.PNG


so in the point 1.. will be the exterior label.. but i want no change the exterior text. this label doesn?t wear exterior label is just a display element with a title..

in the point 2.. i have write here the label-2.. to change the code above.. but doesn?t work.. and the label-2 name is show as you can see here..

https://www.selectiumlab.com/index.php/ca/resultats

how can i change the code text using the label format in this element??

if we can solve that i think we can make all the labels in diferent languages and close this post.

thanks

other question, i didn?t know exactly how the proffesional supports works, before make the payment i just read that the support spend one day to answer the doubts, I posted 3 questions, but the other 2 questions i have not recived any new.. and i think there is only one person in support.. can you tell me exactly how it works, because i have to present to the company this thursday , the Fase I, and i need to know the answer to the other 2 questions posted.. thanks
 
I was working on this.. as you told me..

Change the labels works when you have diferent languages and if you want to show the same list in five diferent languages..for this is ok..

but i have found a trouble.

when you have a user and this user belongs to one language for example spanish.. the user logged in their language and imagine is spanish for example.

I would like allow to this user that have one form in spanish, but also give too, the posibility to change this form to other languages..


I have try 3 options..

- 1st. option ... label option.. is not possible because.. if i want that the user in catalan fill a form in other language, if i stay logged in catalan de label appear in catalan, if i stay logged spanish language the form always use the spanish labels.. here i can not give the option to fill the form in other langugage..

-2nd option.. was create a new page with a language selector + button..

you can see here

https://www.selectiumlab.com/index.php/es/resultados

but the trouble is.. if i stay in catalan.. for example .. with the menu in catalan.. and i select castellano.. the url direction is

https://selectiumlab.com/index.php/es/curriculum-candidato-es/curriculum-administracion.... as you see the send to "/es/"

when you see the form, as you are in spanish, the user Menu language changes from catalan to castellano... when the menu should be the same language than the user's logged.. not the form's language.


- 3rd option - create an article... with a fabrik module inside... so if the article is in catalan.. the user menu will not change.. but if the article is not associated to a "item menu", because is the selector language the form associated to the menu..... i can not change article things as category, author, navigation buttons etc.. so the desing is not similar to other pages..

other idea i was thinking

it would be possible to insert or see the form below the button once we select the language in which we want it, instead of going to another page according to the language ...?? i mean if we can insert a form in the same page.. the user language menu will not change.. and i will see the form in the language we need.. but i don?t know how to insert the form in the same page.

Do you have other idea???

thanks

Javier
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top