我应该将Jquery放在母版页中的哪个位置? [英] Where should I place Jquery in master page?

查看:49
本文介绍了我应该将Jquery放在母版页中的哪个位置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我将以下代码放在母版页的Head之间。不工作,也不允许

按钮控件工作。相同的代码在内容页面中运行良好。这是什么错误?如何纠正?



 <   head     runat   =   server >  
< script src = http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min .js >
< / script >
< script >
$(document).ready(function(){
$(#Amla )。hide();
$('#<% = Image4.ClientID %> ')。mouseover(function (){
var div = $(#Amla);
div.animate({left:'357px',width:'74px',top:'330px',height:'33px'},fast);
div.animate({fontSize:'2em'},fast);
$(#Amla)。show();
});
$('#<% = Image4.ClientID %> ')。mouseleave (function(){
var div = $(#Amla);
$(#Amla)。hide();
});
});

解决方案

(document).ready(function(){


< blockquote>(#Amla)。hide();


('#<% = Image4.ClientID %> ')。mouseover(function(){
var div =


I place the following code between 'Head' in master page. Not working and not also allowing
button controls to work. The same code works well in content page. What is the mistake? How to rectify it?

<head runat="server">
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js">
</script>
<script>
    $(document).ready(function() {
    $("#Amla").hide();
  $('#<%=Image4.ClientID %>').mouseover(function(){
  var div = $("#Amla");
  div.animate({ left: '357px', width:'74px',top:'330px', height:'33px' }, "fast");
  div.animate({ fontSize: '2em' }, "fast");
  $("#Amla").show();
  });
  $('#<%=Image4.ClientID %>').mouseleave(function() {
 var div = $("#Amla");
 $("#Amla").hide();
  });
  });

解决方案

(document).ready(function() {


("#Amla").hide();


('#<%=Image4.ClientID %>').mouseover(function(){ var div =


这篇关于我应该将Jquery放在母版页中的哪个位置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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