Maybe not a Zope specific question but the problem arises only with Zope

The documentEdit.dtml page in OFS has this little HTML:
<TEXTAREA NAME="data:text" WRAP="Off"

And what I want to do is trigger a JavaScript that replaces specific
characters in the textarea box to others.
I.e. Replace swedish  with HTML: &ouml;

The problem is the name of the textarea box!
It is called "name:text"
If I replace the name of the textarea box to say "data", then my JavaScript
works fine.
I have tried to "eval" the box, but to no effect.
Any ideas??

Here's the JavaScript source:
<script language="JavaScript1.2">
// function changeChars()
// replace swedish chars with HTML ones.

function changeChars() {
 var box = eval("");
 var datatext = box.value;
var newdatatext;
 newdatatext = datatext.replace("","&aring;");
 newdatatext = newdatatext.replace("","&Aring;");
 newdatatext = newdatatext.replace("","&auml;");
 newdatatext = newdatatext.replace("","&Auml;");
 newdatatext = newdatatext.replace("","&ouml;");
 newdatatext = newdatatext.replace("","&Ouml;");

 box.value = newdatatext;

Here's the JavaScript error:
invalid label.

Zope maillist  -  [EMAIL PROTECTED]
**   No cross posts or HTML encoding!  **
(Related lists - )

Reply via email to