Try changing your click() to the jQuery equivalent. Not sure what effect this would have, though.

JavaScript Code:
  1. $("#errorLink").click();