Problem with linktext and html characters

Alejandro Tejada capellan2000 at yahoo.com
Thu Jun 11 16:07:43 EDT 2009


Recently i was working with linktext and unicode text.
Following the advice published by Devin Asay in his tutorials
about Unicode text, i converted the unicode text to htmltext
for easiest manipulation between fields.

But now, i have this problem with cutoff links

To demostrate this bug, please create  a new stack
with two fields and a button.

Set the script of button 1 to:

on mouseup
set the htmltext of fld 2 to fld 1
end mouseup

Now, paste the following text in field 1:

<a href="goj<font face="helvetica" lang="el">ū</font>on">goj<font face="helvetica" lang="el">ū</font>on</a>

When you click the button, the text of field 2 becomes this:

kon">gojūon
 
The linked text starts at "kon" and ends in the letter "ū", leaving out of
the linktext the last two letters. (Where did this "k" come from?)
The link is messed too and shows as "goj" not as "gojūon".
 
Actually, the expected result was the single word: "gojūon"
as a linked text to the word "gojūon".
 
Notice that other html entities does not show this
problem. For example, paste the following in fld 1
and click button 1:
 
<a href="orden alfabético">ordenación alfabética</a>
 
This produces the expected result:
 
The words: "ordenación alfabética" as a linked text to the words:
"orden alfabético".
 
Thanks in advance for your help to go around this small bug.

alejandro

Visit my site:
http://www.geocities.com/capellan2000/


      


More information about the use-livecode mailing list