if ($(".img_guige").eq(0).length > 0){//元素存在 var first_height=$(".img_guige").eq(0).css("height");//获取第一个元素的高度