CSS 菜单问题
我有一个在 IIS 中本地运行的网站。我还将完全相同的文件和文件夹结构复制到网络服务器。
远程部署的代码工作正常,但本地安装似乎存在 CSS 问题。查找主题文件似乎出现问题。
当我在 IDE 中运行应用程序时,我的 javascript 下拉菜单显示为全白色/不可见,这也表明存在主题或 CSS 问题。但是,当我将代码部署到本地 IIS Web 文件夹并通过 IE 访问它时,出现以下错误。
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Theme 'U-Net' cannot be found in the application or global theme directories.
Source Error:
Line 14: </configSections>
Line 15: <system.web>
Line 16: <pages masterPageFile="~/SysAdmin.Master" theme="U-Net">
Line 17: <controls>
Line 18: <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
然而,它找不到的主题文件似乎位于它应该在的位置 (参见图片) 并且我我很困惑为什么看起来相同的部署会得到不同的结果。
这里是以及它所在的远程服务器的文件夹结构的图像。
我使用比较工具来比较本地和远程网站的目录结构和文件内容。 没有区别。
任何人都可以发现可能存在的差异或建议检查什么?
查看本地 IIS 配置。
不确定“创建应用程序”按钮对我有什么作用。我想我通常会选择这个选项。不确定它是如何在远程服务器上设置的,我没有权限。
奇怪:当我在 IIS 5 中按下虚拟文件夹的“创建应用程序”按钮时,在尝试访问该站点时收到此错误。
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[NullReferenceException: Object reference not set to an instance of an object.]
SysAdmin.Page_Load(Object sender, EventArgs e) +132
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +50
System.Web.UI.Control.LoadRecursive() +141
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627
该网站需要使用 Windows 身份验证。这就是安全性。
感谢您阅读完这篇长文。任何建议将不胜感激。 IIS 某处配置错误。
I have a web site running locally in IIS. I also copied the exact same files and folder structure to a web server.
The remotely deployed code works fine, but the local installation appears to have a CSS issue. It appears to be having a problem finding a theme file.
When I run the app in the IDE, my javascript drop down menus, appear all white/imnvisible, which suggests also a theme or CSS issue. But when I deploy the code to a local IIS web folder and access it thru IE, I get the following error.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Theme 'U-Net' cannot be found in the application or global theme directories.
Source Error:
Line 14: </configSections>
Line 15: <system.web>
Line 16: <pages masterPageFile="~/SysAdmin.Master" theme="U-Net">
Line 17: <controls>
Line 18: <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
Yet, the theme file that it cannot find appears to be where it should be (See image) and I am confused why to deployments that appear identical get different results.
Here's and image of the folder structure of the remote server where it works.
I used a comparison tool to compare the dir structure and the file contents of both local and remote web sites. There is no difference.
Can anyone spot what the difference may be or suggest what to check?
Check out the local IIS configuration.
Not sure about what the "Create App" button does for me. I thought I usually run with this option. Not sure how it is set on the remote server, I don't have rights to it.
Strange: When I push the Create app button for the Virtual folder in IIS 5, I get this error when I try to access the site.
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[NullReferenceException: Object reference not set to an instance of an object.]
SysAdmin.Page_Load(Object sender, EventArgs e) +132
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +50
System.Web.UI.Control.LoadRecursive() +141
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627
The site needs to use Windows Authentication.This is the security.
Thanks for getting to the end of this long post. Any suggestions would be appreciated. Somewhere, IIS is configured wrong.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我不知道为什么,但我重新安装了 IIS,一切又恢复正常了。不过,当我尝试在另一个驱动器上创建网站时,我遇到了同样的问题。然而,重新安装 IIS 将我的主网站默认位置固定在 inetpub 下,所以我想我相对满意。
I have no idea why, but I reinstalled IIS and everything worked again. Although, when I tried to create a site on another drive, I had the same issue. However, reinstalling IIS fixed my primary web site default location under inetpub, so I guess I relatively happy.