I have two languages added in umbraco so I can add two dictionary values for a key.
For example. I want to set my product name label in website, so I create one dictionary item to set lable. When I create dictionary item, then there will be two input boxes for language 1 and language 2. But when I shaw in database cmsLanguageText table, I noticed that there are total three values for Language 1, 2 and language Id = 0
I don't understand why there is languageId=0 value in cmsLanguageText table.
My second issue is suppose, I keep blank value for language 2, so when I select language 2 then label is shown nothing, I want to get default value if other language value does not apply in dictionary.
Regarding the second issue you could create a .Net function which will return the dictionary item value if exists, otherwise if the dictionary item is empty for that particular language then you can get the value of the primary language.
what about primary language? how we can decide which one is primary language?
Supposen, I have dutch and france languages only in website and both value is empty then lable will be empty for that. We must have some other input box for standard pattern which must be have value and it should insert with language id =0 as my issue no 1. As I said in my previous post, that umbraco inserting blank value in table cmsLanguageText table with languageid=0 that must have some value but we don't have input for that in dictionaryitem page.
Umbraco dictionary issue
I have two languages added in umbraco so I can add two dictionary values for a key.
For example. I want to set my product name label in website, so I create one dictionary item to set lable. When I create dictionary item, then there will be two input boxes for language 1 and language 2. But when I shaw in database cmsLanguageText table, I noticed that there are total three values for Language 1, 2 and language Id = 0
I don't understand why there is languageId=0 value in cmsLanguageText table.
My second issue is suppose, I keep blank value for language 2, so when I select language 2 then label is shown nothing, I want to get default value if other language value does not apply in dictionary.
Thanks
Imran
Regarding the second issue you could create a .Net function which will return the dictionary item value if exists, otherwise if the dictionary item is empty for that particular language then you can get the value of the primary language.
Cheers
Robert
what about primary language? how we can decide which one is primary language?
Supposen, I have dutch and france languages only in website and both value is empty then lable will be empty for that. We must have some other input box for standard pattern which must be have value and it should insert with language id =0 as my issue no 1. As I said in my previous post, that umbraco inserting blank value in table cmsLanguageText table with languageid=0 that must have some value but we don't have input for that in dictionaryitem page.
Thanks
Imran
is working on a reply...