实例106.页面背景选择器.html
来自「JavaScript精彩网页特效实例精粹」· HTML 代码 · 共 21 行
HTML
21 行
<body>
<table border=0 cellpadding=0 cellspacing=0>
<tr STYLE='cursor:hand'>
<td width=20 height=20 style="background-Color:#000000" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#0000ff" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#cccccc" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#ffffff" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#ffff00" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#0000ff" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
</tr>
<tr STYLE='cursor:hand'>
<td width=20 height=20 style="background-Color:#ff0000" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#00ffff" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#336699" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#336633" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#cc3322" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
<td width=20 height=20 style="background-Color:#ddcc33" onclick="javascript:document.body.style.backgroundColor=this.style.backgroundColor;"></td>
</tr>
</table>
</body>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?