How to open a URL in a new Tab using JavaScript or jQuery

This is as simple as this.

Use window.open():

Function description:

name is a name of the window. Following names are supported:

  • _blank – URL is loaded into a new tabThis is default.
  • _parent – URL is loaded into the parent frame
  • _self – URL replaces the current page
  • _top – URL replaces any framesets that may be loaded

Leave a Reply