Question

body tag: <a href="javascript:gotoURL();">T&Cs</a>

head tag:

function gotoURL() {

        window.location = 'someurl.html';

    }

Not working, any idea?

Était-ce utile?

La solution

Modify the function:

function gotoURL() {
  window.location.href = "someurl.html";
}

Source: How can I make a redirect page in jQuery/JavaScript?

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top