在母版页中引用时,jQuery在内容页中不起作用 [英] jquery doesnt work in content page when referenced in master page
本文介绍了在母版页中引用时,jQuery在内容页中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
当我通过从内容页面中删除而在母版页中引用文件时,JQuery不起作用.
仅当我分别引用每个页面时,它才能正常工作.
我也尝试使用resolveurl("")
引用路径,但是问题没有解决.
使用嵌套的母版页.
需要帮助.
谢谢
Hi,
JQuery doesnt work when i referened the file in masterpage by removing from content pages.
It only works fine when i seperately refernece to every page.
i have also tried referenced path using resolveurl("")
but problem didnt solve.
Nested master pages are used.
Need help.
Thanks
推荐答案
你好Mr.shan
您可以尝试使用这种方式
< script type ="text/javascript" src =<%= Request.ApplicationPath%>/Contents/javascript/jquery/jquery-1.6.1.min.js"></script>
您的目录"是存放所有脚本文件的文件夹
希望这会有所帮助
Hello Mr.shan
YOu can try using this way
<script type="text/javascript" src="<%=Request.ApplicationPath%>/Contents/javascript/jquery/jquery-1.6.1.min.js"></script>
Where your "contents" is the folder where you kept all your script files
Hope This Will Help
这篇关于在母版页中引用时,jQuery在内容页中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文