I have a fresh installation of umbraco (4.0.3) and for the first time I'm playing around dictionary Items.
Here are the steps:
1.setting Languages in tab settings - in my case, it looks like this:
Italian (Italy)
English (United Kingdom)
German (Germany)
French (France)
2. adding 1 Entry to the Dictionary (I name it brandNewEntry) and fulfill translation fields. Now, clicking on Dictionary, brandNewEntry has been added and all languages have a green checked-on.
3 on a new template, using xhtml1.1 dtd, I'm calling my dictionary like this (using insert umbraco dictionary item)
<umbraco:Item field="#brandNewEntry" textIfEmpty="alt Text for #brandNewEntry" runat="server"></umbraco:Item>
4. I also want to use xlt for the header so I wrote:
As you can see, I tried two solutions for getting my dictionary entry with method GetDictionaryItem, using the name or a variable. But both don't work and in html code, every call to GetDictionaryItem is just a blank while the page only displays "alt Text for #brandNewEntry".
have you added host names. Is you site structure like this
- go to the node "en" in the content tree right mouse , select manage host name. Enter in you domain name ( doesn't need to be correct ) enter language "english"
- update - Do the same for other languages. - Now go developer, dictionary and enter in the keywords
If I use manage host name, I have a string which have been previously deleted (so an old translation and not the actual one) Is this a cache problem ? Is it possible to force cache deleting ?
problem using Dictionary - Where am I wrong ?
I have a fresh installation of umbraco (4.0.3) and for the first time I'm playing around dictionary Items.
Here are the steps:
1.setting Languages in tab settings - in my case, it looks like this:
2. adding 1 Entry to the Dictionary (I name it brandNewEntry) and fulfill translation fields.
Now, clicking on Dictionary, brandNewEntry has been added and all languages have a green checked-on.
3 on a new template, using xhtml1.1 dtd, I'm calling my dictionary like this (using insert umbraco dictionary item)
<umbraco:Item field="#brandNewEntry" textIfEmpty="alt Text for #brandNewEntry" runat="server"></umbraco:Item>
4. I also want to use xlt for the header so I wrote:
<xsl:template match="/">
<xsl:variable name="dicoItem">brandNewEntry</xsl:variable>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><xsl:value-of select="umbraco.library:GetDictionaryItem($dicoItem)"/></title>
<meta name="Keywords">
<xsl:attribute name="content"><xsl:value-of select="umbraco.library:GetDictionaryItem('brandNewEntry')"/></xsl:attribute></meta>
</xsl:template>
As you can see, I tried two solutions for getting my dictionary entry with method GetDictionaryItem, using the name or a variable. But both don't work and in html code, every call to GetDictionaryItem is just a blank while the page only displays "alt Text for #brandNewEntry".
Where Am I wrong ? Thanks for your help.
have you added host names. Is you site structure like this
- go to the node "en" in the content tree right mouse , select manage host name. Enter in you domain name ( doesn't need to be correct ) enter language "english"
- update
- Do the same for other languages.
- Now go developer, dictionary and enter in the keywords
Sorry mean to say.
Is you site structure like this
Content
- En
- Fr
So you need to add the host names at the root of each language
No, there is no such a structure. I was planing to use the multi tab method for language as explained in http://umbraco.org/documentation/books/multilingual-11-sites
Now, I have deleted all languages, set EN-US as primary language and now, the dictionary entry displays on the page but only in English even if the test browsers are all located in Italy. I thought that dictionary entries somehow should detect default language of your browser. Am I wrong with this ?
If I use manage host name, I have a string which have been previously deleted (so an old translation and not the actual one) Is this a cache problem ? Is it possible to force cache deleting ?
is working on a reply...