Results 1 to 7 of 7

Thread: bug in asp.net

  1. #1

    Thread Starter
    Hyperactive Member Arrow_Raider's Avatar
    Join Date
    Dec 2001
    Location
    AVR Lovers Club
    Posts
    423

    bug in asp.net

    i think i found a bug in asp.net, it stops compiling if it sees </script> anywhere in the code part of the file. i am using it because i am using response.write to append a javascript thing if certain conditions are met.
    My monkey wearing the fedora points and laughs at you.

  2. #2

    Thread Starter
    Hyperactive Member Arrow_Raider's Avatar
    Join Date
    Dec 2001
    Location
    AVR Lovers Club
    Posts
    423
    the reason for this i see is that it uses </script> to stop the code section..... what should i do?
    My monkey wearing the fedora points and laughs at you.

  3. #3

    Thread Starter
    Hyperactive Member Arrow_Raider's Avatar
    Join Date
    Dec 2001
    Location
    AVR Lovers Club
    Posts
    423
    ok i thought of something and it worked, i just did chr(60) for <
    My monkey wearing the fedora points and laughs at you.

  4. #4
    PowerPoster Arc's Avatar
    Join Date
    Sep 2000
    Location
    Under my rock
    Posts
    2,336
    Hmm that seems odd. I dont see why that would cause it to freeze up. I mean it is just a string.

    If you say

    Response.Write ("<script = javascript>asdasd</script>")

    I can't imagine why that would cause a problem.... it is just a string like any other string.

    Maybe if you put

    Response.write (<script = javascript>asdasd</script>)

    then i could see why it would.
    -We have enough youth. How about a fountain of "Smart"?
    -If you can read this, thank a teacher....and since it's in English, thank a soldier.


  5. #5
    Frenzied Member
    Join Date
    Oct 2002
    Location
    Gammapolis
    Posts
    1,474
    I use javascripts with response.write and it works fine. Like this:
    Response.Write("<script = javascript>alert('This is a JavaScript')</script>")
    'Heading for the automatic overload'
    Marillion, Brave, The Great Escape, 1994

    'How will WE stand the FIRE TOMORROW?'
    Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979

  6. #6

    Thread Starter
    Hyperactive Member Arrow_Raider's Avatar
    Join Date
    Dec 2001
    Location
    AVR Lovers Club
    Posts
    423
    well i did have it in quotations, i don't know why it wasn't working, anyways i did the chr(60) thing and it all works now
    My monkey wearing the fedora points and laughs at you.

  7. #7
    Member Stef's Avatar
    Join Date
    May 2001
    Posts
    41
    I've had the same problem. ASP.NET seems to do this when processing code in a <script runat="server"> block. <% ... %> blocks seem to work fine. Definitely smells like bug to me...

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