js 对象不支持此属性或方法

[复制链接]
查看11 | 回复1 | 2009-7-23 20:38:09 | 显示全部楼层 |阅读模式
function m1(){
var left_bot = new Fx.Tween($('left_bot'));
if($('p1').getStyle('height')=='149px')
{
$('menu1').set('class','');
var myhg = new Fx.Tween($('p1'));

myhg.start('height', '149','0');

left_bot.start('height', '0','149');
}
else
{
$$('#p12,#p2,#p3,#p4,#p5,#p6,#p7,#p8,#p9,#p10,#p11').setStyle('height','0');
$$('#menu12,#menu2,#menu3,#menu4,#menu5,#menu6,#menu7,#menu8,#menu9,#menu10,#menu11').set('class','');

$('menu1').set('class','title');

var myhg = new Fx.Tween($('p1'));

myhg.start('height', '0','149');

left_bot.start('height', '149','0');
}
}
这段代码放在JS文件里的 调用时是这样:
[url=][/url]
[U]

[url=]夹克[/url]
[url=]大衣[/url]
[url=]开襟衫[/url]
[url=]休闲上衣[/url]

[/U]

每次都提示:对象不支持此属性或方法。
求大侠们

回复

使用道具 举报

千问 | 2009-7-23 20:38:09 | 显示全部楼层
应该是少了function $(id){
return document.getElementById(id);}...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行