Search code examples
internet-explorerbackbone.jssocketstream

have to click twice to trigger Backbone router in IE 6


I'm developing a real time website using socketstream and backbone.js, everything else was just sorted out to be working pretty well for me except the backbone router, it isn't fired correctly when you click the link once, you have to click it twice to trigger the backbone routing handler, which seems to be pretty weird here, any ideas out there to get this worked around?


Solution

  • IE6 has a problem with routes that start with a slash. Ensure that your links don't have a slash before the route.

    this link will load the route on the second click (only in IE6):

    #/route
    

    to get it working in IE6 use this:

    #route