Randy Webb wrote:
Thomas 'PointedEars' Lahn said the following on 10/16/2007 5:24 AM:
> <select size="6" ...
onclick="this.form.elements['S1'].value += this.value;">
<option>DELETE</option>
onchange="alert(this.value)" and test it in IE......
<form action="..." ...>
...
<textarea rows="4" name="S1" cols="48"></textarea>
<select size="6" ...
onclick="this.form.elements['S1'].value +=
this.options[this.selectedIndex].text + ' ';">
<option>DELETE</option>
<option>INSERT</option>
<option>UPDATE</option>
</select>
...
</form>
The trailing space is only appended here because this looks like an SQL
statement builder. Evaluating the text cursor position to make this a
statement editor is left as an exercise to the reader.
PointedEars
--
"Use any version of Microsoft Frontpage to create your site. (This won't
prevent people from viewing your source, but no one will want to steal it.)"
-- from <http://www.vortex-webdesign.com/help/hidesource.htm>