spaces between each character?

Devin Asay devin_asay at byu.edu
Mon May 22 17:12:31 EDT 2006


On May 22, 2006, at 3:05 PM, Todd Geist wrote:

> Hello,
>
> I am loading an xml file into a field using "put URL"  but there are
> spaces bewteen each character. I know this has something to do with
> the encoding, but I don't know what to do about it
>
>
> here is my script
>
>  answer File "pick"
>    put  "file:"& it into tURL
>    put URL tURL into field "field"
>
> here is what the text looks like in the field
>
> "þÿ < ? x m l   v e r s i o n = " 1 . 0 "   e n c o d i n g = " U T  
> F - 8 " ? >
> < p r o j e c t s >
>     < p r o j e c t >
> "
>
> etc. etc.
>
>
> Any ideas

Todd,

Try uniencoding it:

    answer File "pick"
    put  "binfile:"& it into tURL
    put URL tURL into myVar
    set the unicodeText of field "field" to uniencode(myVar,"utf8")

HTH

Devin


Devin Asay
Humanities Technology and Research Support Center
Brigham Young University




More information about the use-livecode mailing list