document.write函数的用法?
2个回答
展开全部
里面的内容为字符串形式,要加双引号
也可以是HTML代码,如下内容:铅唯
<script language=javascript>
document.write ("<marquee scrollamount='1' scrolldelay='30' direction= 'UP' onmouseover=this.stop() onmouseout=this.start() width='400' id='helpor_net' height='265' align='center' onmouseover='ik8_com.stop()' onmouseout='ik8_com.start()' Author:redriver; For more,visit:www.ik8.com>")
document.write ("<p><font color='pink' face=华文行楷 size=3> ")
document.write ("<p> 小时候的梦想")
document.write ("<p> 从来就不曾遗忘")
document.write ("<p> 找个世上最美的新娘")
document.write ("<p> 陪你到地久天长")
document.write ("<p> 爱你到地老天颤激指荒")
document.write ("<p> 用我温柔的心带你一起飞翔")
document.write ("<p> 我想打开心房")
document.write ("<p> 让你在心中回荡")
document.write ("<p> 拥有每个梦你的夜晚")
document.write ("<p> 当接茄配触你的眼光")
document.write ("<p> 我的心地旋天转")
document.write ("<p> 意乱情迷的我为你痴狂")
document.write ("</font>")
document.write ("</marquee> ")
</script>
也可以是HTML代码,如下内容:铅唯
<script language=javascript>
document.write ("<marquee scrollamount='1' scrolldelay='30' direction= 'UP' onmouseover=this.stop() onmouseout=this.start() width='400' id='helpor_net' height='265' align='center' onmouseover='ik8_com.stop()' onmouseout='ik8_com.start()' Author:redriver; For more,visit:www.ik8.com>")
document.write ("<p><font color='pink' face=华文行楷 size=3> ")
document.write ("<p> 小时候的梦想")
document.write ("<p> 从来就不曾遗忘")
document.write ("<p> 找个世上最美的新娘")
document.write ("<p> 陪你到地久天长")
document.write ("<p> 爱你到地老天颤激指荒")
document.write ("<p> 用我温柔的心带你一起飞翔")
document.write ("<p> 我想打开心房")
document.write ("<p> 让你在心中回荡")
document.write ("<p> 拥有每个梦你的夜晚")
document.write ("<p> 当接茄配触你的眼光")
document.write ("<p> 我的心地旋天转")
document.write ("<p> 意乱情迷的我为你痴狂")
document.write ("</font>")
document.write ("</marquee> ")
</script>
展开全部
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<META NAME="Generator" CONTENT="EditPlus">蠢激
<META NAME="Author" CONTENT="">
<META NAME="Keywords"脊档岁 CONTENT="">
<META NAME="Description" CONTENT="">
</HEAD>樱睁
<BODY>
<script language="javascript">
<!--
document.write("testtest<br/>testtest");
// -->
</script>
</BODY>
</HTML>
=================
Writes one or more HTML expressions to a document in the specified window.
Syntax
document.write(sText)
Parameters
sText Required. String that specifies the text and HTML tags to write.
Return Value
No return value.
Remarks
You should not use the write or writeln methods on the current document after the document has finished loading unless you first call the open method, which clears the current document's window and erases all variables.
<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<META NAME="Generator" CONTENT="EditPlus">蠢激
<META NAME="Author" CONTENT="">
<META NAME="Keywords"脊档岁 CONTENT="">
<META NAME="Description" CONTENT="">
</HEAD>樱睁
<BODY>
<script language="javascript">
<!--
document.write("testtest<br/>testtest");
// -->
</script>
</BODY>
</HTML>
=================
Writes one or more HTML expressions to a document in the specified window.
Syntax
document.write(sText)
Parameters
sText Required. String that specifies the text and HTML tags to write.
Return Value
No return value.
Remarks
You should not use the write or writeln methods on the current document after the document has finished loading unless you first call the open method, which clears the current document's window and erases all variables.
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询
广告 您可能关注的内容 |