SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Evangelist SpaceFrog's Avatar
    Join Date
    Jan 2005
    Location
    Outerspace
    Posts
    511
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    avoid stop running script message

    Hello again !

    I have a rather long script that is not appreciated by browsers, they throw a message something a long script is actually runnning would you like to stop it ?

    Is there any way I can avoid this message and have the script run untill it's end ?

  2. #2
    SitePoint Member
    Join Date
    Jan 2007
    Location
    Cologne, Germany
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    What in the the world do you do with the script that takes so long?
    The abort script normally only appears when there sth like an infinitive loop, and that's OK because otherwise the browser would crash

  3. #3
    SitePoint Evangelist SpaceFrog's Avatar
    Join Date
    Jan 2005
    Location
    Outerspace
    Posts
    511
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    well actually I have different scripts that throw me that message, one of them deals with colors ... and there are no infinite loops in them, just very long ones ...

  4. #4
    Programming Since 1978 silver trophybronze trophy felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, NSW, Australia
    Posts
    16,810
    Mentioned
    25 Post(s)
    Tagged
    1 Thread(s)
    The only way to get rid of that message is to reduce the time that it takes for your code to run. There is nothing that can be done with javascript that should need such complex processing as to trigger that message. You would need Javascript the size of dozens or hundreds of web pages in one script to get that alert without it being in a loop.
    Stephen J Chapman

    javascriptexample.net, Book Reviews, follow me on Twitter
    HTML Help, CSS Help, JavaScript Help, PHP/mySQL Help, blog
    <input name="html5" type="text" required pattern="^$">


Bookmarks

Posting Permissions

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