多语言 asp.net 站点,具有不同级别的 aspx

发布于 2024-09-30 05:32:50 字数 500 浏览 7 评论 0原文

我一直在使用 asp.net 和 Visual C# 构建多语言网站。 我正在使用 Local_resources 获取西班牙语和英语的 aspx 文件。 如果在网站的根目录中使用我的 aspx,则 Local_resources 文件夹会找到适合我的 aspx 的 resx(因为两者具有相同的名称)。但是,如果我将所有 aspx 放入根目录中创建的文件夹中,则一切都会停止工作:

alt text

如您所见我有一个名为“Inventario”的文件夹,在该文件夹中我有 Productos.aspx。 在 App_LocalResources 中,我有两个文件,一个用于西班牙语,一个用于英语。 如果我将 Productos.aspx 放在根目录中,它们可以正常工作,但我需要它们,就像图像中那样,但这样不起作用。
我应该如何处理 resx 文件以指向 Inventario/Productos.aspx ?

非常感谢。

I've been working in a multilanguage site build with asp.net and visual c#.
I'm using Local_resources to get my aspx files in Spanish and english.
If a use my aspx in the root of the website the Local_resources folder find the aproppiate resx for my aspx (because both have the same name). But if i put all my aspx into a folder created in the root directory, everything stop working:

alt text

as you can see i have a folder named "Inventario" and inside that folder i have Productos.aspx.
In App_LocalResources i have two files, one for spanish and one for english.
If i put Productos.aspx in the root directory they work fine, but i need them like in the image and like that is not working.
What should i do to the resx files to point to Inventario/Productos.aspx ?

Thank you very much.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

︶ ̄淡然 2024-10-07 05:32:50

您必须在 Inventario 下创建一个新的 App_LocalResources 文件夹,然后从 \ 复制 Productos.aspx.*.resx App_LocalResourcesInventario\App_LocalResources,然后重建您的解决方案。

You have to create a new App_LocalResources folder under Inventario, then copy Productos.aspx.*.resx from <root>\App_LocalResources to Inventario\App_LocalResources, then rebuild your solution.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文