Updated postProcess, link should open in new window or tab

This commit is contained in:
Wu Cheng-Han 2015-09-25 18:18:21 +08:00
parent 2463a5126b
commit bb13a98c13
1 changed files with 4 additions and 0 deletions

View File

@ -207,6 +207,10 @@ function postProcess(code) {
result.find("iframe").replaceWith(function () {
return "<noiframe>" + $(this).html() + "</noiframe>"
});
//link should open in new window or tab
result.find('a:not([target])').attr('target', '_blank');
return result;
}
}
}
}