带有资源文件的站点地图 [英] Sitemap with Resource File
问题描述
我有一个站点地图设置,它可以正常工作,但是当我尝试对其进行本地化时,一切都崩溃了.我是这个
< mvcsitemapnode title ="$ resources:Message,Contact" controller ="Portal" action ="Overview">
并得到错误
System.InvalidOperationException:找不到类名称为"Message"且键为"Contact"的资源对象.
奇怪的是,该资源可在我放置的任何网页上使用(复制并粘贴以确保拼写正确). enableLocalization也设置为true.
资源:消息,请联系"controller =" Portal"action =" Overview>
并得到错误
System.InvalidOperationException:找不到类名称为"Message"且键为"Contact"的资源对象.
奇怪的是,该资源可在我放置的任何网页上使用(复制并粘贴以确保拼写正确). enableLocalization也设置为true.
任何帮助都将非常有用!
这并不是一个完整的解决方案,但只有在使用全局资源文件的情况下,它才能正常工作.
>
I have a sitemap setup and it works fine but when I try to localize it, it all falls apart. I''m this
<mvcsitemapnode title="$resources: Message, Contact" controller="Portal" action="Overview">
and it get the error
System.InvalidOperationException: The resource object with classname ''Message'' and key ''Contact'' was not found.
The strange thing is that this resource works on any webpage I put it on (copy and pasted to make sure spelling wasn''t wrong). enableLocalization is also set to true.
Any help would be great!
resources: Message, Contact" controller="Portal" action="Overview">
and it get the error
System.InvalidOperationException: The resource object with classname ''Message'' and key ''Contact'' was not found.
The strange thing is that this resource works on any webpage I put it on (copy and pasted to make sure spelling wasn''t wrong). enableLocalization is also set to true.
Any help would be great!
Not really a complete solution but I''ve only got it to work if I use a global resource file.
这篇关于带有资源文件的站点地图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!