For my small wiki application, I mostly need to have the textarea used to edit the contents to use soft (or virtual) wrapping. However, in some cases, not wrapping the content would be preferable. I thought I would do this by simply having a button to turn off wrapping. Here is the simplified code:
<form name="wikiedit" action="[[script_name]]" method="post">
<textarea name="content" rows="25" cols="90" wrap="virtual">[[content]]</textarea>
<input type="button" onclick="document.wikiedit.content.wrap='off';" value="No Wrap">
<input type="submit" value="Save">
</form>
It works with IE, but not with Firefox or Opera. How should I do this?