dcsimg
A Flash Developer Resource Site

Results 1 to 12 of 12

Thread: Special characters from Asp to flash

  1. #1
    Junior Member
    Join Date
    Apr 2002
    Posts
    5
    I've got a little problem on which I've been rushing all day long !

    It's about special characters loaded from an asp page. The string loaded in flash produced by an asp page looks like this "QtyAnswer=5&sQuestion=%C0+quel+moment", and was perfectly running before I switched to MX.

    You can see that the first character in the second variable that is loaded is "%C0", result from a URLEncode of the character "".

    When it comes to my flash, there is no more trace of this character (""), it is replace by a square ("�").

    I tried everything ! I read all posts... no one solve my problem ! HELP ME PLEASE !!!!!

    Thanks so much

  2. #2
    Aquarium drinker
    Join Date
    Nov 2000
    Location
    Greater than 45 degrees in Minkowski space
    Posts
    571
    Hmmm, I think your problem is that the font you're using in the textfield doesn't include the French characters. Try a different font, see if it works.

  3. #3
    Junior Member
    Join Date
    Apr 2002
    Posts
    5

    Wouldve been great...

    If Arial font doesnt support french chars... i throw myself in the fire !!!

    Thanks anyways

  4. #4
    Junior Member
    Join Date
    Mar 2001
    Posts
    12

    same problem with scandinavian characters

    I understand your frustration.
    I've tested dynamic text fields both with Flash 5 and MX.
    With F5, scandinavian characthers () works fine, and not with MX.
    I constantly check for an update of the F6 player, but so far, 6,0,23,0 is the latest player.
    However, if you look at the output of the publishing report, there has been changes in the output of exported characters for the movie.
    Look at the differences in the two examples below.
    after "{|}" there is changes, and the position of some characthers have changed. Does this matter for the output, or am I "way off" here? (it's just an output report...)


    Flash 5
    Verdana 20507 !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~* *

    Flash MX
    Verdana 20283 !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~ **



  5. #5
    Junior Member
    Join Date
    Apr 2002
    Posts
    5
    It seems interesting... and were getting near a solution methinks...

    But not near enough for now... cause it doesnt solve my problem... maybe it is really a flash player bug ! cause I saw no one having this problem solved neither.

    And its the same for me, it worked fine with flash 5 and the bug appeared when I transformed it into an MX.

    It is also very strange that the 1 or 2 following characters are chunked.

  6. #6
    Junior Member
    Join Date
    Mar 2001
    Posts
    12
    It seems to me that the characters between (and including) the "unrecognized" character and the next space disappears.


  7. #7
    Aquarium drinker
    Join Date
    Nov 2000
    Location
    Greater than 45 degrees in Minkowski space
    Posts
    571
    I have a feeling it may have something to do with new Unicode support in Flash 6. Have you tried encoding it as %00C0 instead?

  8. #8
    The problem is that the Flash Player 6 uses Unicode and your French text is not Unicode. If you do not want to use UTF-8 Unicode, then a simple workaround is to use the following ActionScript on your movie's first frame: System.useCodepage=true


    Here's some more information from Flash Blog (http://radio.weblogs.com/0102755/stories/2002/03/21/flashMxBugsissues.html)

    <b>International Character Support (Gotcha/Lack of Documentation)</b>

    In the authoring tool: In the MX authoring tool, you can enter any characters in your current code page. For English (and other European) systems, this is Latin-1 or MacRoman. The OS doesn't support the entry of Chinese characters (for example) into entry fields because the code page doesn't support it.

    For actionscript, you can work around this by #include of an actionscript file. The .as file should be UTF8 and contain the first line:

    //!-- UTF8

    so that MX will know its a UTF-8 text file. You can put any characters in any language in that file that you wish, and should be correctly displayed by the Flash Player.

    In the Flash player: The Flash player is completely Unicode. It can display in any language available on your OS, and take input in any language supported by your OS. This varies by OS: NT, 2K, and XP will allow an English system to run a Japanese IME, which will put Japanese characters into dynamic text fields, mixed with any other language you have input support for. Output is supported in any language you have font packs for. (Although it is limited to left to right character sets.) The 9x kernels are somewhat more limited, but still support multi language output in almost all cases.

    When loading data (via LoadVariables or XML) the Flash 6 player will assume UTF-8 encoding unless system.useCodepage = true, in which case it will load in the current codepage, Latin-1 in the case above. This does mean that if you load Latin-1 data, that contains high ASCII, into a Flash Player 6 without useCodepage set, it will be garbage! The encoding is not set correctly. You need to use UTF-8 data or set useCodepage.


  9. #9
    Junior Member
    Join Date
    Apr 2002
    Posts
    5

    I've also tried that: System.useCodepage=true

    I've put it on the first keyframe of the first layer, the first kf of the last layer... still with no result !!

    Am i doing something wrong ?

    loadVariablesNum ("../inserts/insertFlashQuestion.asp", 0);

    There's nothing wrong there ?!?!?! no ?


  10. #10
    Junior Member
    Join Date
    Apr 2002
    Posts
    5
    Originally posted by pmineault
    I have a feeling it may have something to do with new Unicode support in Flash 6. Have you tried encoding it as %00C0 instead?
    My variable simply doesnt load when i do that ! grrrrrrr

  11. #11
    I got it to work by escaping the characters with \u

    For example to display character

    Use: \u00C7

    00C7 is the Unicode character for . You can find the Unicode chars values by running Charmap.exe on Windows XP.

    If you running Mac OS X, you can use an application called FontChecker http://wundermoosen.com/ to find the Unicode char values.

    If you do not have XP, do a search on Google for Unicode character values.

    Hope this helps,

    -- Jossi

  12. #12
    Junior Member
    Join Date
    Sep 2001
    Posts
    6
    Hi,

    I was having the same problem loading text from a PHP script, using System.useCodepage=true;
    was working, however that was not the solution I was looking for.

    I solved the problem just aplying the PHP function utf8_encode() to my text string:

    $string = " ...";
    $string = utf8_encode($string);
    echo "texto=$string";

    Hope you have some function like this one in ASP,

    Good LUCK

    HP

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center