Use .click instead of window location