Clive Atkins Clive Atkins - 2 months ago 7x
Javascript Question

Jquery attr Open New Window

I am trying to open a URL in Jquery which works fine however I would like the window to open in a target _new way.

<script src=""></script>
$(location).attr('href', '');

I have tried adding


and some variations but to no joy. Thanks in advance.


If you want open url in new page you can use:"", '_blank');