Monday, December 24, 2012

jQuery to Open all Hyperlinks in Separate Window

Find jQuery code to open all hyperlinks on a page to open in separate browser window. It is indeed a good feature as this ensures that user still be able to read/go through current page contents.
$(document).ready(function() {
  $('a').attr('target', '_blank');
});
See result below


Feel free to contact me for any help related to jQuery, I will gladly help you.