DebugBar Forums
 
 HOME 
 DOWNLOAD 
 BUY 
 DOC / WIKI 
 FORUM 
 CONTACT 
Stay tuned : rss feed

Forum Home


advanced search

You are not logged in.

Announcement

Forums are now closed as we moved them to google groups. You can use the following Google Groups to discuss about DebugBar and IETester products:

#1 2012-02-21 15:53:50

fmmarzoa
New member

Problems with onclick on a link

Following code seems to not work on IE Tester:

<a href="javascript:void(0);" onClick="validarFormularioReserva()">Continuar</a>

Same code works fine in the same machine on an IE9 standalone instance, so I think it is an IE Tester issue.

You can test it here:

(User / Pass = test / 1234)

http://test.asturocio.es/reservas.php?id=18

Pressing the red arrow with "Continuar" text on the left below the table.

Best regards,

Offline

 

#2 2012-02-21 17:07:03

ifugu
New member

Re: Problems with onclick on a link

I'm having the same problem with a variation of the href: <a href="javascript:" id="mylink">Link text</a>

The click event handler is assigned by jQuery:

$('#mylink').click(function () {
  // my code
});

The value of the href attribute ends up in the address bar and the click event handler does not execute.  This behavior is seen in IE6-9 tabs.  It works properly when using IE directly.

It's worth noting that setting href="#" resolves the problem in IETester.

Windows 7 Pro SP1 64bit, IE9 installed
IETester v0.4.11
IE6-9 tabs

Offline

 

#3 2012-04-06 16:48:39

ssanders
New member

Re: Problems with onclick on a link

I had similar trouble with an href onClick in IE8 and prior. onClick was "terms();" which simply called

Code:

function terms() {
    if(document.getElementById('terms').style.display == "block") {
        document.getElementById('terms').style.display = "none";
    } else {
        document.getElementById('terms').style.display = "block";
    }
}

Ultimately I changed the onClick to just "document.getElementById('terms').style.display='block';" which lost the cool click on/off but worked.

I don't think it was IETester though. A user on IE7 said the link was failing too.

Offline