Skip to content
This repository has been archived by the owner on Jun 7, 2020. It is now read-only.

alexrabarts/jquery-newwindow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

newWindow: a jQuery plugin

newWindow is a super-simple jQuery plugin for opening new browser windows when an anchor is clicked.

Usage

Open all links with a rel attribute of external in a new window:

  $('a[rel~=external]').newWindow();

Add a callback when a new window is opened:

  $('#myLink').newWindow({
    open: function (newWindow, e) {
      console.log('Window opened', newWindow, e);
    }
  });

Licensing

Licensed under the MIT: http://www.opensource.org/licenses/mit-license.php

Copyright (c) 2011 Stateless Systems (http://statelesssystems.com)

About

A super-simple jQuery plugin for opening new browser windows when an anchor is clicked.

Resources

Stars

Watchers

Forks

Packages

No packages published