dcsimg
A Flash Developer Resource Site

Results 1 to 9 of 9

Thread: ASP and Flash

  1. #1
    Junior Member
    Join Date
    Nov 2001
    Posts
    6

    ASP and Flash

    I am trying to read an asp file with flash. That works when asp generates normal characters. For example

    Asp generates

    hello
    hello2

    Flash shows

    hello
    hello2

    So that's OK

    But when asp generates special characters flash can't read them. For example:

    Asp generates

    hello&
    hello2

    Flash shows:

    hello

    What's the problem and how can I solve it? It has to do something with special characters

  2. #2
    Member
    Join Date
    Jan 2001
    Posts
    49
    with the Ampersand (&) you tell Flash to expect a new variable

    So, if you send something like this text1=hello&hello2&text2=yourName Flash expects hello2 to be a variable but it gets no value...... So all of the following variables will also stop to be read.

    The answer.

    There are several Characters, that can be solved with an 'Escape sequence' like variable1=hello \"name\" is here

    For the Ampersand (&) you will have to use the 16bit unicode \u0026

    (actual unicode Charts http://www.unicode.org/charts)


    (example: Cigarettes=Benson \u0026 Hedges&smoking=no would give you two variables : Cigarettes("Benson & Hedges) smonking("no"))


    attetion: the font you are using in the textfield must be embededd totally, that means check the [.......] in the textoptions!! and if your desired font has no character for the character you've sent
    (some Fontsets don't have the -Sign, for example, it won't show up either)

    Anway, have fun and the

  3. #3
    Hammer
    Join Date
    Mar 2001
    Location
    Warrington UK
    Posts
    274
    good article on asp and flash.

    http://www.asp101.com/articles/flash/index.asp

  4. #4
    Junior Member
    Join Date
    Nov 2001
    Posts
    6

    no answer

    Originally posted by garethwdesign
    good article on asp and flash.

    http://www.asp101.com/articles/flash/index.asp
    thanks for all your trouble but that article won't solve my problem.

  5. #5
    Junior Member
    Join Date
    Nov 2001
    Posts
    6
    I have tried your solution but when I let ASP generate hello \u0026 hello

    flash shows: hello \u0026 hello

    Flash must show: hello & hello

  6. #6
    Member
    Join Date
    Jan 2001
    Posts
    49
    yes, you're right.... i've got this from the helpfile included with the flashpackage... sorry, can't help you then

  7. #7
    Hammer
    Join Date
    Mar 2001
    Location
    Warrington UK
    Posts
    274
    When you say youo are trying to read an asp file does that mean you are trying to read variables in from the asp page or that you are trying to read the whole page?

  8. #8
    Junior Member
    Join Date
    Nov 2001
    Posts
    6

    whole asp page

    Originally posted by garethwdesign
    When you say youo are trying to read an asp file does that mean you are trying to read variables in from the asp page or that you are trying to read the whole page?
    I am reading the whole asp page.
    The whole page is put in a variabele





  9. #9
    Registered User
    Join Date
    Nov 2001
    Location
    Conneticut
    Posts
    5

    Text to Flash

    Hi In you ASP page you must URLEncode the text before sending it to Flash. Then if it still displays improperly you need to escape() the variable and your text should be fine. I did this with a large ASP/Flash site a while ago and am writing this from memory

    Look up actionscript "escape()" and "unescape()" and ASP "URLEcode"

    asp example "fnHelp =(Server.URLEncode(rsHeader.Fields.Item("nHelp").V alue))"

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