Version Description
- Fixed bug opening links containing html tags (like )
Download this release
Release Info
| Developer | freelancephp |
| Plugin | |
| Version | 1.54 |
| Comparing to | |
| See all releases | |
Code changes from version 1.53 to 1.54
- js/src/wp-external-links.js +3 -2
- js/wp-external-links.js +1 -1
- readme.txt +4 -1
- wp-external-links.php +2 -2
js/src/wp-external-links.js
CHANGED
|
@@ -38,7 +38,7 @@
|
|
| 38 |
}
|
| 39 |
}
|
| 40 |
|
| 41 |
-
if ($
|
| 42 |
// jQuery DOMready method
|
| 43 |
$(function () {
|
| 44 |
$('a').live('click', function (evt) {
|
|
@@ -50,7 +50,8 @@
|
|
| 50 |
addEvt(window, 'load', function () {
|
| 51 |
var links = window.document.getElementsByTagName('a');
|
| 52 |
var eventClick = function (evt) {
|
| 53 |
-
|
|
|
|
| 54 |
};
|
| 55 |
var a;
|
| 56 |
var i;
|
| 38 |
}
|
| 39 |
}
|
| 40 |
|
| 41 |
+
if ($) {
|
| 42 |
// jQuery DOMready method
|
| 43 |
$(function () {
|
| 44 |
$('a').live('click', function (evt) {
|
| 50 |
addEvt(window, 'load', function () {
|
| 51 |
var links = window.document.getElementsByTagName('a');
|
| 52 |
var eventClick = function (evt) {
|
| 53 |
+
var target = this instanceof Element ? this : evt.target;
|
| 54 |
+
openExtLink(target, evt);
|
| 55 |
};
|
| 56 |
var a;
|
| 57 |
var i;
|
js/wp-external-links.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
| 1 |
/* WP External Links */
|
| 2 |
-
(function(){"use strict";function t(e,t,n){if(e.attachEvent){e.attachEvent("on"+t,n)}else if(e.addEventListener){e.addEventListener(t,n,false)}}function n(e,t){var n=e.getAttribute("data-wpel-target");var r=e.getAttribute("href");var i;if(r&&n){i=window.open(r,n);i.focus();if(t){if(t.preventDefault){t.preventDefault()}else if(typeof t.returnValue!=="undefined"){t.returnValue=false}}}}var e=jQuery===undefined?null:jQuery;if(e
|
| 1 |
/* WP External Links */
|
| 2 |
+
(function(){"use strict";function t(e,t,n){if(e.attachEvent){e.attachEvent("on"+t,n)}else if(e.addEventListener){e.addEventListener(t,n,false)}}function n(e,t){var n=e.getAttribute("data-wpel-target");var r=e.getAttribute("href");var i;if(r&&n){i=window.open(r,n);i.focus();if(t){if(t.preventDefault){t.preventDefault()}else if(typeof t.returnValue!=="undefined"){t.returnValue=false}}}}var e=jQuery===undefined?null:jQuery;if(e){e(function(){e("a").live("click",function(e){n(this,e)})})}else{t(window,"load",function(){var e=window.document.getElementsByTagName("a");var r=function(e){var t=this instanceof window.Element?this:e.target;n(t,e)};var i;var s;for(s=0;s<e.length;s+=1){i=e[s];t(i,"click",r)}})}})()
|
readme.txt
CHANGED
|
@@ -3,7 +3,7 @@ Contributors: freelancephp
|
|
| 3 |
Tags: links, external, icon, target, _blank, _new, _none, rel, nofollow, new window, new tab, javascript, xhtml, seo
|
| 4 |
Requires at least: 3.4.0
|
| 5 |
Tested up to: 3.9.1
|
| 6 |
-
Stable tag: 1.
|
| 7 |
|
| 8 |
Open external links in a new window or tab, adding "nofollow", set link icon, styling, SEO friendly options and more. Easy install and go.
|
| 9 |
|
|
@@ -106,6 +106,9 @@ In this case all internal links will be made bold.
|
|
| 106 |
|
| 107 |
== Changelog ==
|
| 108 |
|
|
|
|
|
|
|
|
|
|
| 109 |
= 1.53 =
|
| 110 |
* Fixed bug also opening ignored URL's on other tab/window when using javascript
|
| 111 |
* Changed javascript open method (data-attribute)
|
| 3 |
Tags: links, external, icon, target, _blank, _new, _none, rel, nofollow, new window, new tab, javascript, xhtml, seo
|
| 4 |
Requires at least: 3.4.0
|
| 5 |
Tested up to: 3.9.1
|
| 6 |
+
Stable tag: 1.54
|
| 7 |
|
| 8 |
Open external links in a new window or tab, adding "nofollow", set link icon, styling, SEO friendly options and more. Easy install and go.
|
| 9 |
|
| 106 |
|
| 107 |
== Changelog ==
|
| 108 |
|
| 109 |
+
= 1.54 =
|
| 110 |
+
* Fixed bug opening links containing html tags (like <b>)
|
| 111 |
+
|
| 112 |
= 1.53 =
|
| 113 |
* Fixed bug also opening ignored URL's on other tab/window when using javascript
|
| 114 |
* Changed javascript open method (data-attribute)
|
wp-external-links.php
CHANGED
|
@@ -4,14 +4,14 @@ Plugin Name: WP External Links
|
|
| 4 |
Plugin URI: http://www.freelancephp.net/wp-external-links-plugin
|
| 5 |
Description: Open external links in a new window/tab, add "external" / "nofollow" to rel-attribute, set icon, XHTML strict, SEO friendly...
|
| 6 |
Author: Victor Villaverde Laan
|
| 7 |
-
Version: 1.
|
| 8 |
Author URI: http://www.freelancephp.net
|
| 9 |
License: Dual licensed under the MIT and GPL licenses
|
| 10 |
*/
|
| 11 |
|
| 12 |
// constants
|
| 13 |
if (!defined('WP_EXTERNAL_LINKS_FILE')) { define('WP_EXTERNAL_LINKS_FILE', __FILE__); }
|
| 14 |
-
if (!defined('WP_EXTERNAL_LINKS_VERSION')) { define('WP_EXTERNAL_LINKS_VERSION', '1.
|
| 15 |
if (!defined('WP_EXTERNAL_LINKS_KEY')) { define('WP_EXTERNAL_LINKS_KEY', 'wp_external_links'); }
|
| 16 |
if (!defined('WP_EXTERNAL_LINKS_DOMAIN')) { define('WP_EXTERNAL_LINKS_DOMAIN', 'wp-external-links'); }
|
| 17 |
if (!defined('WP_EXTERNAL_LINKS_OPTIONS_NAME')) { define('WP_EXTERNAL_LINKS_OPTIONS_NAME', 'WP_External_Links_options'); }
|
| 4 |
Plugin URI: http://www.freelancephp.net/wp-external-links-plugin
|
| 5 |
Description: Open external links in a new window/tab, add "external" / "nofollow" to rel-attribute, set icon, XHTML strict, SEO friendly...
|
| 6 |
Author: Victor Villaverde Laan
|
| 7 |
+
Version: 1.54
|
| 8 |
Author URI: http://www.freelancephp.net
|
| 9 |
License: Dual licensed under the MIT and GPL licenses
|
| 10 |
*/
|
| 11 |
|
| 12 |
// constants
|
| 13 |
if (!defined('WP_EXTERNAL_LINKS_FILE')) { define('WP_EXTERNAL_LINKS_FILE', __FILE__); }
|
| 14 |
+
if (!defined('WP_EXTERNAL_LINKS_VERSION')) { define('WP_EXTERNAL_LINKS_VERSION', '1.54'); }
|
| 15 |
if (!defined('WP_EXTERNAL_LINKS_KEY')) { define('WP_EXTERNAL_LINKS_KEY', 'wp_external_links'); }
|
| 16 |
if (!defined('WP_EXTERNAL_LINKS_DOMAIN')) { define('WP_EXTERNAL_LINKS_DOMAIN', 'wp-external-links'); }
|
| 17 |
if (!defined('WP_EXTERNAL_LINKS_OPTIONS_NAME')) { define('WP_EXTERNAL_LINKS_OPTIONS_NAME', 'WP_External_Links_options'); }
|
