如何在Asp.ne 4.0中使用Java脚本菜单作为Web用户控件 [英] how to use java script menu using as Web User Control in Asp.ne 4.0

查看:102
本文介绍了如何在Asp.ne 4.0中使用Java脚本菜单作为Web用户控件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在Asp.ne 4.0中使用Java脚本菜单作为Web用户控件.问题是CSS样式无法应用用户控件.但它可以正常使用Pages.如果我将CSS用作用户控件而不应用于普通页面

how to use java script menu using as Web User Control in Asp.ne 4.0 t. The problem is CSS styles are not applying throgh user control. but it works normal Pages. if i use as user control the CSS not Applied to the normal pages

推荐答案

问题是CSS样式无法应用于用户控件.但可以正常使用Pages
样式表文件的URL似乎未正确引用.在正常页面期间,给定的参考路径找到文件并应用css,但是通过用户控制,该路径的格式不正确,因此在给定位置找不到该文件,不允许任何CSS应用于.

确保CSS文件路径正确形成或应用css文件内本身.

看看这个技巧,可能会有所帮助:解析多路径-Folder WebSite [
The problem is CSS styles are not applying throgh user control. but it works normal Pages
It looks like the URL for the stylesheet file is not referenced properly. During normal page, the reference path given finds the file and applies the css but through User-control, the path is not correctly formed and hence the file is not found at the given location not letting any CSS to apply.

Make sure that the CSS file path is correctly formed or apply the css in-file itself.

Have a look at this tip, it might help: Resolving Paths in a Multi-Folder WebSite[^]


这篇关于如何在Asp.ne 4.0中使用Java脚本菜单作为Web用户控件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆