<script type="text/javascript">
document.getElementById('x').style.background="url(" + bg + ")"
<p>本例演示如何向 textarea 插入背景图像。</p>
<p>请把鼠标移动到图像上,textarea 会获得一幅背景图像:</p>
<table width="300" height="100">
<td onmouseover="bgChange('/img/eg_bg_08.gif')"
background="/img/eg_bg_08.gif"></td>
<td onmouseover="bgChange('/img/eg_bg_09.gif')"
background="/img/eg_bg_09.gif"></td>
<textarea id="x" rows="5" cols="20">
This example can not be edited
because our editor uses a textarea
and your browser does not allow
a textarea inside a textarea.