DOM
来源:互联网 发布:网络代理服务器 编辑:程序博客网 时间:2024/05/21 07:13
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title> new document </title>
<meta name="generator" content="editplus" />
<meta name="author" content="" />
<meta name="keywords" content="" />
<meta name="description" content="" />
<script type="text/javascript">
function showDiv(){
var new_div = document.createElement('div');
new_div.style.width = '222px';
new_div.style.height = '222px';
new_div.align='center';
new_div.style.backgroundColor = 'pink';
new_div.id='div1';
document.body.appendChild(new_div);
var text = document.createTextNode('圣诞老公公');
new_div.appendChild(text);
alert(document.getElementById('div1').nodeName);
}
</script>
<input type="button" onclick="showDiv()" value="click">
</head>
<body>
</body>
</html>
- DOM
- DOM
- dom
- dom
- DOM
- dom
- DOM
- DOM
- DOM
- DOM
- DOM
- dom
- dom
- Dom
- dom
- DOM
- DOM
- DOM
- 缓存
- org.hibernate.exception.ConstraintViolationException: could not insert解决
- JavaScript+总结(四)
- 图的割点、桥与双连通分支
- 风险 采购 管理
- DOM
- [Arduino 教程] BareMinimum-从零开始
- 图像处理——卷积
- 开篇留个纪念
- Smarty中缓存中定义及应用缓存
- org.hibernate.hql.ast.QuerySyntaxException: Unable to locate appropriate constructor on class XXX解决
- 缓存小知识
- 百度面试题
- VS2010与水晶报表V13的打包集成小结