1、动态创建一个全功能的<img>元素:
$('<img>',{
src:'jump/img/f_banner.png',
alt:'hello img!',
title:'just for test',
click:function(){
alert("hello,img!!!");
}
}).css({
border:'1px solid red',
cursor:'pointer',
padding:'5px'
}).appendTo('body');
原文:http://blog.csdn.net/comeonstone/article/details/43452449