作者tom21tom21 (平凡就好)
看板Ajax
标题[ js ] 如何js表格写入textarea里面
时间Mon Dec 1 19:53:33 2008
我的意思
例如我写一个function 要写出一个表格在我指定的textarea里面
举一个例子
function displayCalendar(month, year) {
document.write("<TABLE BORDER=2 bordercolor=#8080FF CELLSPACING=2
CELLPADDING=2>");
document.write("<TR ALIGN=center>");
document.write("<TD><FONT SIZE=2 face=arial COLOR=\"#FF0000\">星期日
</FONT>");
document.write("<TD><FONT SIZE=2 face=arial color=000000>星期一</FONT>");
document.write("<TD><FONT SIZE=2 face=arial color=000000>星期二</FONT>");
document.write("<TD><FONT SIZE=2 face=arial color=000000>星期三</FONT>");
document.write("<TD><FONT SIZE=2 face=arial color=000000>星期四</FONT>");
document.write("<TD><FONT SIZE=2 face=arial color=000000>星期五</FONT>");
document.write("<TD><FONT SIZE=2 COLOR=\"#FF0000\">星期六</FONT>");
document.write("</TABLE>");
}
<body>
<textarea FONT="Courier" NAME="calPage" WRAP=no ROWS=8 COLS=22>
</textarea>
</body>
请问在document那边要什麽写
感谢各位大大
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 218.174.41.40
1F:→ blinkstar:观念已经严重错误 = =" 12/01 21:03
2F:推 chph:table 不能放textarea里面 12/01 22:23