日期:2014-05-16 浏览次数:20556 次
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" >
<html>
<head>
<meta name="description" content="this is my page"/>
</head>
<script>
window.onload = function () {
var metaEl = document.getElementsByTagName("meta");
alert(metaEl[0].name + "###" + metaEl[0].content);
metaEl[0].content = "my content";
alert(metaEl[0].name + "###" + metaEl[0].content);
};
</script>
<body>
<div style="background-color:#ff0000; width:200px;">this is some div</div>
<div style="background-color:#00FF00; width:200px;">another div</div>
</body>
</html>