jQuery location href

I think you are looking for:

window.location = 'http://someUrl.com';

It's not jQuery; it's pure JavaScript.


There's no need for jQuery.

window.location.href = 'http://example.com';

Use:

window.location.replace(...)

See this Stack Overflow question for more information:

How do I redirect to another webpage?

Or perhaps it was this you remember:

var url = "http://stackoverflow.com";
location.href = url;

This is easier:

location.href = 'http://address.com';

Or

location.replace('http://address.com'); // <-- No history saved.