Better Popunder JS

#1 Popunder Script on the market

Version 3.x.x includes fewer APIs, but it is more powerful and gives better results. The entire script has been rewritten.

Last updated: 2025/01/08

Table Of Contents

Introduction

BetterJsPop is the #1 popunder script on the market, written in JavaScript by Thanh Cong since 2012. It was originally shared for free but was not updated frequently; in late 2015 it became a paid premium script, with many improvements.

  • Opens pop-unders, pop-ups, tab-unders and tab-ups, and works on every desktop and mobile browser.
  • Bypasses Adblock Plus.
  • Supports multiple URLs, random URLs and hooks.
  • Uses modern syntax and is very easy to set up.
  • Filters mobile and desktop traffic.
  • Supports asynchronous loading.
  • Can bind to, or ignore, specific HTML tag names or DOM elements.
  • Hides the traffic source.
  • Comes with a complete API and documentation.
  • And more.
About Bypass Adblock

Our script can open pops even when Adblock is enabled. Unfortunately, if your pop URL is on Adblock's blocklist, Adblock will close the pop window or tab right after it opens. We used to bypass this with a redirector trick, but Adblock has since updated its mechanism to work like uBlock Origin: it monitors the URLs of all tabs and windows and closes any that match its blocklist.

If your pop URL is not on their blocklist, congratulations! You can use our script to open your pops even when Adblock is enabled.

Installation

To install the script, upload the following files to your server:

script.js and license.XX.js, where XX is a random number.

If you are working in a local environment, you can use local domains such as 127.0.0.1 or *.local to test the script.

Note: license.XX.js is your license file. We will email it to you after you have registered your domains with us. Do not use the license file included in updates or in the .zip file; it is only a demo license and does not work in a production environment.

For example, if your domain is domain.com, after uploading the files you will have the following links:

http://domain.com/script/script.js http://domain.com/script/license.XX.js

Here is a basic setup to see how it works:

<script src="http://domain.com/script/script.js"></script>
<script src="http://domain.com/script/license.XX.js"></script>
<script>
BetterJsPop.add('http://example.com', {under: true, tab: false});
</script>

You can use our merger tool at https://popunderjs.com/merger.php to merge the script and the license file into one file, which makes uploading to your server easier. The tool also provides some tweaks to help the script run better.

Note: The page must be served over http:// or https://. Do not open your HTML file by double-clicking it; the script may not work with the file:// protocol.

Configuration

By default, the script uses BetterJsPop as its variable name. You can change it to any name you want to avoid conflicts with other ad networks (many of our customers are ad networks). To change the variable name, add window.popns = 'YourOwnName' at the top of script.js or before loading script.js. For example:

<script>window.popns = 'YourOwnName';</script>
<script src="http://domain.com/script/script.js"></script>
<script src="http://domain.com/script/license.XX.js"></script>
<script>YourOwnName.add('http://example.com');</script>

This is the manual method; you can also use our Merger Tool to do this.

The following config options are available, with their default values:

Option Type Default
prefix string BetterJsPop
perPage integer -1
bindTo Array null
ignoreTo Array null
interval integer 0
debug boolean false
fallback Object { under: true, tab: true }
mobileSensitive integer 15
noOpenner boolean true
noReferrer boolean false
allowScrollbar boolean true
allowPopUnderTrick boolean true
blankAnchor string TAB_UNDER

To use these options, pass them to .config().

For example:

BetterJsPop.config({
    debug: true,
    perPage: 5
});
Option: perPage

In earlier versions this option was named perpage; both names work in version 3.

Limits the number of pops per page load. The default is -1 (no limit). You can add multiple URLs to the stack using .add(), and the script will open them one after another, one per user click.

Option: bindTo

An array of query selectors or DOM elements. The script will only open a pop when the user clicks one of these elements.

Option: ignoreTo

An array of query selectors or DOM elements. The script will not open a pop when the user clicks one of these elements.

Option: interval

In earlier versions this option was delay, in milliseconds; since 3.x it is expressed in seconds.

The number of seconds to wait between two pops, to avoid spamming users and "pop-up blocked" messages.

Option: debug

Enable this option to see log messages. Alternatively, use BetterJsPop.Logger.print() to print all queued messages.

Option: blankAnchor

WebKit only allows one pop or tab to be opened per click; more cannot be opened at once. If the user clicks a link with target="_blank", the script can open either the pop or that link, but not both.

IGNORE: The script does nothing when the user clicks a _blank anchor.

TAB_UNDER: Opens a tab-under: the link opens in the focused tab, and the pop URL opens in the tab underneath.

PREVENT: Opens the pop and prevents the link's default behavior.

Option: fallback

In earlier versions this option was named popFallbackOptions; both names work in version 3.x.

When a pop-under is not available, the script uses this option to open the pop.

The default is tab-under: { under: true, tab: true }.

You can change it to pop-up with { under: false, tab: false },

or to tab-up with { under: false, tab: true }.

Option: mobileSensitive

mobileSensitive controls our fast-click technique. If the user scrolls only a short distance, the script may treat it as a click and open the pop quickly.

The default value is 15. Larger values are more sensitive and can trigger a pop while the user is scrolling.

The value should be a number from 5 to 30. Do not set it higher than 30.

Option: noOpener

A global setting that prevents the pop window from redirecting the main window through window.opener.location. You can override this setting for each pop.

Option: noReferrer

A global setting that hides the referrer. You can override this setting for each pop.

Option: allowScrollbar

In earlier versions this option was named coverScrollbar; both names work in version 3.x.

Allows the script to fire a pop when the user clicks the scrollbar. The default value is true.

Option: allowPopUnderTrick

Creates a small window and then moves it around. When the user clicks back on the main window, the small window becomes a pop-under.

Limit Domains For Unlimited Package

The unlimited package means any website can embed and use your script. If you want to prevent this and allow only certain domains, simply open your license file and add the following code at the top:

window[window.popns || 'BetterJsPop'].href = ['domain1.com', 'domain2.com'];
...

Add new pop

To add a new pop to the queue, use the .add() method.

BetterJsPop.add('http://example.com', {});

Pop Options {}

Each pop supports the following options:

  • name, type string
    • The name of the pop window. Each pop has a unique name by default; you can change it if you want.
  • device type string, default "any", accepted values "desktop", "mobile" or "any"
    • Filters the traffic for the pop, for example when you want to open the pop only on "mobile" or only on "desktop".
  • expires type integer or DateTime, default: session
    • By default, pops are tied to the browser session, which means the user has to close their browser to get a new pop. You can change this to a number of seconds or a DateTime value. (read more)
    • For example, to show the pop every 30 minutes, use expires: 1800.
  • under type boolean, default true
    • Set this to false to open a pop-up instead.
  • tab type boolean, default false
    • Set this to true to use a tab instead of a new window.
  • shouldFire type function(pop, event, target)
    • Lets you add your own logic to decide whether the pop should fire.
    • Your logic runs after the main logic, so if the main logic decides not to fire the pop, returning true will not make it fire.
    • You can use this to open the pop only when the user clicks a specific element. (read more)
  • beforeOpen type function(pop), default: NOOP
    • Called before the pop is fired.
  • afterOpen type function(pop, popWin), default: NOOP
    • Called after the pop is fired.
    • popWin references the window object of the pop (when using a pop-up or pop-under).
  • noReferrer type boolean, default false
    • Set this to true to hide the referrer for the pop URL.
  • noOpenner type boolean, default true
    • Set this to true to hide the opener for the pop URL.
  • tabUnderUrl type string or function(url), default null
    • When using tab-under, use this hook to customize the URL of the new tab, for example to add extra parameters.
  • You can also use the width, height, top and left options to customize the pop window's size and position.
Example: use pop options

Here is a basic example of how to use pop options:

BetterJsPop
.add('http://example.com/url1', {
    under: true,
    tab: false
})
.add('http://example.com/url2', {
    device: 'desktop',
    expires: 900, // open every 15 minutes. Note: the user still has to click the page content to get a pop
    beforeOpen: function(pop) {
        console.log('pop url', pop.url);
    },
    afterOpen: function(pop, popWin) {
        console.log('after pop open', pop, popWin);
    }
})
Example: shouldFire option
BetterJsPop.add('http://example.com', {
    shouldFire: function(pop, event, target) {
        return target === jQuery('#your-element')[0];
    }
});
Pop option: expires

By default, the script uses a session cookie for each pop, so once a pop has fired, the user has to close the browser to get a new one.

You can also set expires to a DateTime or to an integer number of seconds.

To open a pop on every click, use expires: 0.

API

config() method

Configures the script. For all available options, see the Configuration section.

/**
 * @param options object
 * @return self
 */
BetterJsPop.config(options);

getConfig() method

Returns all options the script is currently using.

/**
 * return object
 */
BetterJsPop.getConfig();

add() method

Adds a pop to the queue. The pop fires when the user clicks the page content.

/**
 * @param url       string|function
 * @param options   object or not defined.
 * @return self
 */
BetterJsPop.add(url, options);

You can pass a function as the URL to get a random URL, or to run your own logic before the pop URL is determined.

Example with random URLs:

// Each time before this pop opens, the script calls the function to get a new URL.
BetterJsPop.add(function() {
    var urls = [
        'http://example.com/?url1',
        'http://example.com/?url2'
    ];
    return urls[Math.floor(Math.random() * urls.length)];
});

You can also call .add() multiple times to add more pops:

BetterJsPop.add('http://example1.com');
BetterJsPop.add('http://example2.com');
BetterJsPop.add('http://example3.com');

Or chain the calls like this:

// Remember: do not put `;` after each `add`
BetterJsPop
    .add('http://example.com')
    .add('http://example2.com')
    .add('http://example3.com')

getStack() method

Returns all added pops.

/**
 * @return array
 */
BetterJsPop.getStack();

emptyStack() method

Removes all added pops from the stack. This does not remove the cookie flags. To remove the cookies as well, use the reset() method instead.

/**
 * @return void
 */
BetterJsPop.emptyStack();

bindTo() method

Binds the pop to specific tag names or DOM nodes.

/**
 * @param string|array|multiple arguments
 * @return self
 */
BetterJsPop.bindTo(arguments);

Example:

// Bind the script to all <img> tags
BetterJsPop.bindTo('img');

// Bind to all <a> tags
BetterJsPop.bindTo('a');

// Bind to more than one tag
BetterJsPop.bindTo(['button', 'img']);

// or
BetterJsPop.bindTo('button', 'img');

// @since 2.5.16 - Selectors are supported
BetterJsPop.bindTo(['#id-of-element', '.class-of-elements']);

// To clear the bind/ignore list, use
BetterJsPop.bindTo(false);

To bind the script to all elements with a given class name:

jQuery(document).ready(function($) {
  $('.your-class-name').each(function () {
    BetterJsPop.bindTo(this);
  });
});

ignoreTo() method

Works the same as bindTo(), but tells the script not to open a pop when the user clicks the ignored elements or DOM nodes.

/**
 * @param string|array|multiple arguments
 * return self
 */
BetterJsPop.ignoreTo(arguments);

getBindTo() method

/**
 * @return array DOM elements
 */
BetterJsPop.getBindTo();

getIgnoreTo() method

/**
 * @return array DOM elements
 */
BetterJsPop.getIgnoreTo();

reset() method

/**
 * Deletes all cookies and flags so that pops can fire again without reloading the page.
 */
BetterJsPop.reset();

Logger API

Logger.log() method

/**
 * Adds a message to the log. If debug mode is enabled, the message is also written to the console immediately.
 * Accepts multiple arguments, like console.log().
 */
BetterJsPop.Logger.log(arguments)

Logger.print() method

/**
 * Prints all log messages to the console.
 */
BetterJsPop.Logger.print();

Cookie.set() method

/**
 * Sets a cookie.
 *
 * @param name string
 * @param value mixed
 * @param expires DateTime|integer number of seconds 
 * @param attributes object
 */
BetterJsPop.Cookie.set(name, value, expires, attributes);

Cookie.get() method

/**
 * Gets a cookie by name.
 *
 * @param  string
 * @return string|null
 */
BetterJsPop.Cookie.get();

Cookie.remove() method

/**
 * Removes a cookie by name.
 *
 * @param string name
 */
BetterJsPop.Cookie.remove(name);

Storage API

Storage.set() method

/**
 * Sets a storage item.
 *
 * @param string    name
 * @param mixed     value
 */
BetterJsPop.Storage.set(name, value);

Storage.get() method

/**
 * Gets a storage item by name.
 *
 * @param  string       name
 * @return string|null
 */
BetterJsPop.Storage.get(name);

Storage.remove() method

/**
 * Removes an item by name.
 *
 * @param name string
 */
BetterJsPop.Storage.remove(name);

Storage.clear() method

/**
 * Clears all storage items.
 *
 * @param name string
 */
BetterJsPop.Storage.clear();

Browser API

Browser.isLinux property

/**
 * @type boolean
 */
BetterJsPop.Browser.isLinux;

Browser.isWin property

/**
 * @type boolean
 */
BetterJsPop.Browser.isWin;

Browser.isMac property

/**
 * @type boolean
 */
BetterJsPop.Browser.isMac;

Browser.isIOS property

/**
 * @type boolean
 */
BetterJsPop.Browser.isIOS;

Browser.isAndroid property

/**
 * @type boolean
 */
BetterJsPop.Browser.isAndroid;

Browser.isMobile property

/**
 * @type boolean
 */
BetterJsPop.Browser.isMobile;

Browser.isWebkit property

/**
 * @type boolean
 */
BetterJsPop.Browser.isWebkit;

Browser.isMozilla property

/**
 * @type boolean
 */
BetterJsPop.Browser.isMozilla;

Browser.isChrome property

/**
 * @type boolean
 */
BetterJsPop.Browser.isChrome;

Browser.isFirefox property

/**
 * @type boolean
 */
BetterJsPop.Browser.isFirefox;

Browser.isSafari property

/**
 * @type boolean
 */
BetterJsPop.Browser.isSafari;

Browser.isIE property

/**
 * @type boolean
 */
BetterJsPop.Browser.isIE;

Browser.isEdge property

/**
 * @type boolean
 */
BetterJsPop.Browser.isEdge;

Browser.isOpera property

/**
 * @type boolean
 */
BetterJsPop.Browser.isOpera;

Browser.version property

/**
 * Returns the browser's version number
 * @type integer
 */
BetterJsPop.Browser.version;

Browser.longVersion property

/**
 * Returns the browser's full version number
 * @type string
 */
BetterJsPop.Browser.longVersion;

Browser.versionCompare method

/**
 * Compares the current browser version with the given version.
 * @return boolean
 */
BetterJsPop.Browser.versionCompare(operator, version);

Example:
BetterJsPop.Browser.versionCompare('>=', '10.5');
BetterJsPop.Browser.versionCompare('<', '60');

Changelog

version 3.0.18; 2025/04/14

  • Fixed tab-under duplicate urls.

version 3.0.0; 2025/01/08

  • Rewrite all of the script, focus on performance.
  • Remove outdated method
  • Added new tricky pop under method for all browsers.

version 2.11.28; 2023/04/04

  • Make tab under on mobile do the same on all mobile browser. when click to target=_blank

version 2.11.27; 2022/12/13

  • Auto switch to variable to flag pops if both localStorage and sessionStorage are blocked.

version 2.11.24; 2021/10/23

  • Auto switch to Storage to flag pops if cookie is blocked (3rd party cookie blocked issue in modern browsers)

version 2.11.21; 2021/04/30

  • Fixed infitiny pop issue in Chrome if pop script is loaded inside iframe.

version 2.11.20; 2021/01/31

  • Fallback to tab-under on Firefox 85+

version 2.11.19; 2020/09/15

  • Fixed coverTags sometime not working for new Chrome.
  • Optimize code.

version 2.11.12; 2019/12/12

  • Fixed issue when use mobile mode in Firefox browser.
  • Fixed some small issues.

version 2.11.10; 2019/07/05

  • Fixed popup in Edge 17+

version 2.11.5; 2019/06/14

  • Improved pop performance in mobile.
  • Update to deal with Adblock (please read document)

version 2.11.4; 2019/02/14

  • Fixed some bugs

version 2.11.0; 2019/02/13

  • Fixed pop-under for Firefox 65
  • Fixed pop-under for Opera Window.

version 2.9.3; 2019/02/12

  • Temporarily switch to tab-under for Firefox 65

version 2.9.0; 2019/01/28

  • Added new feature tricksChrome (read docs)

version 2.8.25; 2019/01/24

  • Improved popup behavior
  • Fixed popup issue in MacOS FullScreen mode

version 2.8.24; 2018/12/01

  • Improved cover Tags options.
  • Fixed some small issues

version 2.8.21; 2018/05/30

  • Temporary switch to tab-under in Chrome 67
  • Fixed some smallissues

version 2.8.12; 2018/04/18

  • Try to work and compatible with all older browser versions if possible.
  • Support Yandex browser.

version 2.8.10; 2018/04/17

  • Fixed shouldFire hook not working.
  • Fixed known issues.

version 2.8.7; 2018/04/15

  • Fixed pop under for old browser versions.
  • Fixed issue open many pops (Chrome 64+)
  • Fixed issue in fallback option.

version 2.8.4; 2018/04/13

  • Improved performance.
  • Fixed known bugs.

version 2.8.0; 2018/04/12

  • Fixed popunder for Chrome 64+ Mac, Windows and Safari 11
  • Added Event.bindOnce()
  • Added Utils.isUnderIframe()
  • Removed Utils.addQueryString()
  • Removed Utils.isFlashEnabled()
  • Removed forceUnder option

version 2.7.37; 2018/02/12

  • Temporary switch to tab-under in Chrome 64 .
  • Fixed some small issues.

version 2.7.16; 2017/10/21

  • Fixed popunder on Windows Chrome 62
  • Temporary switch pop-under to tab-under in Safari 11.

version 2.7.7; 2017/09/06

  • Fixed pop under in Windows Chrome 61.
  • Pop under on Mac Chrome will be tab-under without reload current page (temporary solution).
  • Fixed duplicate impression on Android Chrome.

version 2.6.7; 2017/08/09

  • Fixed pop under in Windows Opera 46+

version 2.6.5; 2017/08/08

  • Fixed some small issues.

version 2.6.1; 2017/07/28

  • Fixed pop under in Chrome 60
  • Fixed some small issues.

version 2.5.38; 2017/06/22

  • Improved user experience if pop is loaded and fired from iframe.

version 2.5.34; 2017/05/21

  • Fixed issue if pop script is loaded inside iframe with different domain.

version 2.5.32; 2017/05/11

  • Fixed pop-under issue on Chrome 59
  • Fixed issue on Opera - iOS
  • Fixed other small issues

version 2.5.25; 2017/04/20

  • Improved performance on Firefox 53

version 2.5.24; 2017/04/20

  • Fixed pop under on Chrome 58 Mac.

version 2.5.23; 2017/04/19

  • Fixed pop under on Chrome 60 Windows + Mac.
  • Fixed one small issue.

version 2.5.16; 2017/04/11

  • Fixed pop under issue on Chrome Mac 57.0.2987.133, Chrome Windows 58.
  • ignoreTo() and bindTo() now support selector (.class or #id are supported in all browsers).

version 2.5.11; 2017/04/05

  • Improve pop under performance
  • Fixed some small pop under issues in Chrome 56+ Windows 10

version 2.5.4; 2017/03/29

  • Optimize performance
  • Fixed some issue if embeded in large page.
  • Fixed some important issues

version 2.5.0; 2017/03/27

  • Make the script great again.
  • Works on Chrome 56, 57 Windows, Mac on both Normal and Incognito mode.
  • Works on Opera 43 Windows, Mac both Normal and Incognito mode.

version 2.4.13; 2017/02/21

  • Added new setting initOnload to run pop after window loaded (window.onload) (read document about this). If your page is huge and slowly loading, set this to true on Chrome to avoid pop under issue.

version 2.4.8; 2017/02/14

  • Fixed some small issues
  • Fixed pop-under issue on Firefox Mac 51

version 2.4.2; 2017/01/29

  • Fixed pop-under issue on Chrome Mac 56+
  • Fixed small issue on Chrome Windows 56+

version 2.4.0; 2017/01/28

  • Fixed pop-under issue on Chrome Windows 56+

version 2.3.33; 2017/01/26

  • Fallback to tab-under in Chrome 56
  • Fixed some issues in Android

version 2.3.27; 2017/01/13

  • Now you can disable mobile sensitive by set mobileSensitive to -1
  • Fixed duplicate tab on iOS when slowly click on link with target=_blank.
  • Fixed some small issues.

version 2.3.22; 2016/12/07

  • Fixed some small issue on mobile iOS 10+ when user click to an anchor _blank

version 2.3.21; 2016/12/01

  • Fixed issue in Firefox 50+ when use cookieExpires: -1

version 2.3.20; 2016/11/28

  • Fixed issue in Firefox 50
  • Added fallback to tab-under in Chrome 47 (dev)

version 2.3.18; 2016/11/23

  • Fixed webkitAnchorBlank (true) issue on Chrome if click to internal link

version 2.3.17; 2016/11/19

  • Fixed restore event issue on Safari Mac OS 10

version 2.3.16; 2016/11/18

  • Reduce mobileSensitive on Safari Mobile to avoid redirection issue. If you still facing with this problem, change mobileSensitive to 0

version 2.3.12; 2016/10/24

  • Added **.getStack() **and .emptyStack() API, please use .getStack() insteadof .stack (removed).

version 2.3.11; 2016/10/21

  • Fixed localStorage issue if load page by using data:

version 2.3.10; 2016/10/17

  • Cover some issues may occured in some special cases.
  • Optimized code

version 2.3.3; 2016/10/13

  • Fixed tab-under issue on Safari 10 macOS

version 2.3.2; 2016/10/11

  • Added new feature to limit domains for unlimited package.

version 2.3.1; 2016/10/11

  • Optimized code
  • Fixed duplicate impression in Google Chrome.

version 2.2.54; 2016/10/03

  • Fixed alert box problem in Firefox 49.0.1 (issues of 2.2.52)

version 2.2.52; 2016/09/30

  • Fixed problem with popunder inside iframe on Safai iOS and IE11
  • Fixed popunder on Firefox 49 (Win) (all other pop scripts fail on this case)

version 2.2.49; 2016/09/24

  • Fixed problem with popunder in Safari 10
  • Fixed mobileSensitive option not working
  • Fixed FastClick issue when stack is empty.
  • More stable

version 2.2.38; 2016/08/27 (stable)

  • Added new config option **noOpenerHijiacking **to avoid popped window use window.opener.location. (read document about this)
  • Improved performance.
  • Fixed some know bugs in previous versions

version 2.2.26; 2016/08/21

  • Improved fast click technique
  • Added new config option **mobileSensitive **to control our fast click technique (read document)
  • Fixed small issues
  • More stable.

version 2.2.16; 2016/08/19

  • Fixed tab-under issue if pop inside an iframe.
  • Improve impressions in mobile.

version 2.2.11; 2016/08/18

  • Use fast click technique, should give more impressions on mobile.

version 2.2.8; 2016/08/18

  • Fixed issue if pop inside an iframe.
  • Fixed tab-under issue on Vivaldi browser and some other browsers
  • Improved user experience in Firefox, Safari when use tab-under and clicked to <a target=_blank>
  • Improve performance in Firefox when open pop-under (reduce browser laggy)

version 2.2.0; 2016/08/17

  • Allows to change BetterJsPop variable to other name to avoid conflicts with other adnetworks (due we have lot of adnetwork as customers) (read document)
  • Changed way to open pop (try to open our pop before others)
  • Added new config popFallbackOptions then will use when popunder is not available on desktop.
  • Added reset() API that can open all pop again without refresh page or waiting for cookie expired.
  • Fixed problem with tab under in iframe.
  • Fixed problem on iOS (multiple pop and expiration)
  • Removed justClicked() API

version 2.1.13; 2016/08/16

  • Added new API getLastEvent() to get last mouse event

version 2.1.8; 2016/08/12

  • Improve user experience in mobile when click to a link with target=_blank

version 2.1.7; 2016/08/11

  • Improved user experience in Opera Window
  • Added new API .coverElement() similar to coverTags but can cover any element you want.
  • Improve hook shouldFire, don't need wrap your logic in **justClicked() **any more.
  • Improved Mobile detection
  • Fixed an issue on Android default browser.

version 2.0.18; 2016/08/10

  • Improved performance in mobile

version 2.0.17; 2016/08/09

  • Fixed problem in restoring events (user experience, website behaviors)

version 2.0.16; 2016/08/09

  • Fixed problem when user clicks to element inside <a> with Chrome Popunder

version 2.0.15; 2016/08/08

  • Make coverScrollbar available in all desktop browsers
  • Added new config option webkitAnchorBlank (default: true) to make pop under work on Chrome, Opera even when user click to a link with target=_blank
  • Added new config option **forceUnder **(default: false) check document to understand it.

version 2.0.14; 2016/08/07

  • Added new config option **coverScrollbar ** for Webkit browsers (Chrome, Safari, Opera), increase more pop performance (impressions)

version 2.0.9; 2016/08/04

  • Fixed problem with pop under if user double click to link fast (blank pop window, not full screen)
  • Improve code performance.

version 2.0.7; 2016/08/02

  • It's stable now
  • Improved performance
  • Fixed some bugs

version 2.0.4; 2016/07/27

  • Fixed some know bugs
  • Fixed issue in IE 6 -> 9 (some previous versions do not work by a typo)
  • Optimize the code, smaller size, run faster

version 2.0.2; 2016/07/25

  • Fixed tab-under issue (open wrong url)

version 2.0.1; 2016/07/25

  • Rewrite all the script to version 2.0 - amazing version, work better.
  • Rewrite all document, make it more clear and easier to use.
  • Bring pop under back to Chrome Mac
  • Work fine on Chrome 52, Chrome 54 (Chrome Canary)
  • Since 2.0, we don't provide raw source code any more, just packed version, but provide more APIs, you can use it to integrate with your tracking system or add your logic code to customize it by using hooks.
  • Use .config() to configure it instead of .perpage() or .flashUrl(), etc...
  • Improve pop on most of mobile browsers

version 1.2.0; 2016/07/21

  • Rewrite some codes to make it more dynamic and customizable.
  • Added new shouldFire option, justClicked() API (read document about it)

version 1.1.12; 2016/07/11

  • Fixed small issue with cover object tag + popUnder on Chrome Window
  • Allow pass a function to setTabUnderUrl method

version 1.1.11; 2016/06/23

  • Fixed small bug if website contains too many images and loading slow

version 1.1.10; 2016/06/17

  • Improve some codes, make it better

version 1.1.9; 2016/06/08

  • Fixed pop under issue on Firefox 47

version 1.1.8; 2016/05/31

  • A patch for 1.1.7 it's wrong version and does not make pop under.

version 1.1.7; 2016/05/30

  • Fixed bug if pass a function to .add() method and use multiple pops perpage.
  • Improve some other features

version 1.1.6; 2016/05/25

  • Added more API
  • Disabled covering iframe, video tags as default, if you want to work with iframe, video tags, use .coverTag(['video', 'iframe'])

version 1.1.5; 2016/05/13

  • Fixed bugs crash on Chrome Window, IE11
  • Improved some codes

version 1.1.4; 2016/05/13

  • Fixed issue with pop under on IE11 when open an external url (different domain)

version 1.1.3; 2016/05/12

  • Add new API .coverTags() for managing iframe, video overlay. You also can disable overlay for any tag you want. (check our document)

version 1.1.2; 2016/05/12

  • Fixed a typo in Safari

version 1.1.1; 2016/05/11

  • Supports IE11 again.

version 1.1.0; 2016/05/05

  • Script now can handle when user click to <video>, <iframe> tag.

version 1.0.39; 2016/04/29

  • Add new API .ignoreTo() same as .bindTo() to tell pop under to ignore some elements or DOM nodes.

version 1.0.38; 2016/04/20

  • Improved popunder on Opera Window, now popunder is working as well on Opera all versions.

version 1.0.37; 2016/04/13

  • Fixed issue counting number pop per page wrong on IE11.

version 1.0.36; 2016/04/06

  • Fixed small issue on Chrome Window, when user click to a checkbox/radio, it should make pop and keep browser's normal behavior.

version 1.0.35; 2016/03/27

  • Supports passing url by function means you can use randomly url, do your logic to get pop url for every click (check our document)
  • Fixed small issue with .delay() in Chrome Window.
  • Fixed small issue on couting pop per page with tab.

version 1.0.34; 2016/03/25

  • Fixed issue that .delay() does not work with tab-under.

version 1.0.33; 2016/03/24

  • New option noReferer for hidding traffic source from popped url.

version 1.0.32; 2016/03/23

  • Improved .bindTo() method, now handle click inside element, DOM node better.

version 1.0.31; 2016/03/08

  • Temporary switch to use tab-under in Linux platform due popunder can't works on Linux.

version 1.0.30; 2016/03/03

  • Don't show #:xx in url when open tab-under in all browsers exclude IE (just for counting pop perpage when use tab-under).
  • Fixed issue when remove cookie (typo)

version 1.0.29; 2016/02/29

  • Fixed issue that .perpage() does not work when use tab-under
  • Improve beforeOpen option, now you can add your logic and return false to cancel pop.
  • Fixed issue on Opera Window 32bit.

version 1.0.27; 2016/02/28

  • Fixed small issue with use multiple pop perpage on Safari, Firefox if cookie is expired.
  • Added new API .delay(ms) to set delay between pops

version 1.0.26; 2016/02/21

  • Improved binding to element feature. Now if you bind the pop to a <div> tag, and you click to a <span> inside the <div> it still works fine.

version 1.0.25; 2016/02/18

  • Temporary use tab-under for Opera Window < 35, latest version >= 35 still use pop-under

version 1.0.24; 2016/02/17

  • Added more APIs to BetterJsPop (Browser, Cookie, Logger) (check docs)
  • New feature for changing current url when opens tab-under (check docs)
  • Optimized flash.e.swf

version 1.0.23; 2016/02/08

  • Improve some codes

version 1.0.22; 2016/02/04

  • Fixed some small issues, CS.
  • Optimized some code.
  • Improved multiple tab-unders on Firefox, Opera, Safari.
  • Pass pop object and pop options to beforeOpen, afterOpen handlers.

version 1.0.21; 2016/02/04

  • Supports all MS IE legacy versions (5.5 to 11)

version 1.0.20; 2016/02/02

  • Can make pop under on Opera Mac, Windows as well.
  • Fixed some small issues.

version 1.0.19; 2016/01/26

  • Automatic switch to use tab-under on Chrome, Firefox if flash is ask to active.
  • Fixed popunder issue on Firefox 43.0.3 (Windows)
  • Temporary use tab-under for popunder and tab-under on Mac Chrome 48+ to avoid issue unable to turn off fullscreen mode.

version 1.0.16; 2016/01/21

  • Improved event restoring and tab-under on Safari and Chrome.

version 1.0.15; 2016/01/06

  • Add some code to handle some jQuery plugins such as jquery.select prevents events from html tag and makes this script not working

version 1.0.14; 2015/12/22

  • Added delay between pops on Chrome to avoid facing with Blocking Message when use multiple pop per page.
  • Added new license.php file allows you can manage allowed domain if you have purchased unlimited plan.

version 1.0.13; 2015/12/21

  • Supports Firefox 45.
  • Fixed issues on Firefox 43 (Windows) - version 1.0.13.1

version 1.0.12; 2015/12/18

  • Add some code to handle <object> important CSS issue made by stupid designers (they force whole of <object> tags to { height: auto !important }, that effects to our flash element)

version 1.0.11; 2015/12/17

  • Switch to use tab under on Microsoft Edge.

version 1.0.10; 2015/11/30

  • Add some code to handle Flash is "Ask to active" in firefox.

version 1.0.9; 2015/11/23

  • New API for ignoring element's listeners calling "preventDefault()" or "return false". You should read document about this feature.

version 1.0.8; 2015/11/22

  • Fixed a bug of smart trigger feature on Android default browser, Firefox for android, IE11 desktop.

version 1.0.7; 2015/11/21

  • Fixed a bug if right click to a link in Firefox
  • New API for binding popunder to specific tag names or DOM nodes.
  • Improve some other features to make it smarter.

version 1.0.6; 2015/11/20

  • New option to filter mobie/desktop traffic
  • New option to change cookie name

version 1.0.5; 2015/11/18

  • Improve some features for mobile browsers.
  • Improve multiple tab unders for mobile and some desktop browsers.
  • New smart click trigger for element what user click on to get popunder.

version 1.0.4; 2015/11/16

  • New API for changing license file path.

version 1.0.3; 2015/11/07

  • Improve some features for mobile browsers.

version 1.0.2; 2015/11/05

  • Use fast click technique to make popunder on mobile faster

version 1.0.1; 2015/11/04

  • Fix issues on Safari 9.0.1 on El Capitan (by typo)