Umbraco 7 Working with languages/Dictionary

孤街浪徒 提交于 2019-12-05 05:47:42

First, you have to create your languages under Settings > Languages.

Next step is to set the language on each node, or just on a top node. So lets say your content tree looks like this:"

Then right click on "da" and select "Culture and Hostnames". Select "da-DK" for this node. All subnodes (and "da" node) will now have the danish language.

So now its simple to get dictionary items in razor and c# code. In razor:

@Umbraco.GetDictionaryValue("Answers")
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!