将jquery函数转换为简单的javascripts代码 [英] To convert jquery function to simple javascripts code

查看:74
本文介绍了将jquery函数转换为简单的javascripts代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的jquery函数如下:-
--------------------

My jquery function is below:-
--------------------

$(''img'').load(function() {
    $(this).data(''height'', this.height);
}).bind(''mouseenter mouseleave'', function(e) {
    $(this).stop().animate({
        height: $(this).data(''height'') * (e.type === ''mouseenter'' ? 1.5 : 1)
    });
});



我想将其转换为上述jquery代码的简单javascript代码.

我该如何解决以上问题?
请任何人帮帮我.....



I want to convert as a simple javascript code of above jquery code.

How will i do for above problem???
Please Please help me anybody.....

推荐答案

(''img'').load(function(){
(''img'').load(function() {


(this).data(``height'',this.height); }).bind("mouseenter mouseleave",function(e){
(this).data(''height'', this.height); }).bind(''mouseenter mouseleave'', function(e) {


(this).stop().animate({ 高度:
(this).stop().animate({ height:


这篇关于将jquery函数转换为简单的javascripts代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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