為什么不能改紅色;
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>認識語句</title>
<script type="text/javascript">
? ?document.write("hello").style.color="red";
? ?document.write("world");
</script>
</head>
<body>
</body>
</html>
認識語句
2017-04-27
<script type="text/javascript">
? ? document.write("hello".fontcolor("red"))
</script>
2017-04-27
語法不對??梢詫ⅰ県ello“放在一個有id的<p>標簽中,然后用getElementById("")提取元素,然后對其進行樣式的改變。
2017-04-27
document.write("hello").style.color="red";這樣要能出來就是新的語法規則了。。