I am trying to create a button that will highlight the text in a form so people can copy it.
There will be a lot of text in the form, otherwise I wouldn't worry about it.
This will be posted on a wordpress blog. I've tried it in both firefox and IE and it doesn't highlight the text
<form name="copyThis">
<textarea name="codeToCopy" cols="40" rows="5" readonly="readonly">
Click on the button below to highlight this text.
</textarea>
<br>
<input type="button" value="Highlight All" onclick="javascript
:this.form.codeToCopy.focus();t his.form.codeToCopy.select();">
</form>
Please help thanks in advance