CSDN blog保存为pdf小技巧

1、下载Google Chrome浏览器,在右上角点开设置一栏,找到更多工具—开发者工具
2、在Console中黏贴下面一段代码,然后按回车键即可,当前页面的pdf会自动加载出来。

(function(){
$("#side").remove();
$("#comment_title, #comment_list, #comment_bar, #comment_form, .announce, #ad_cen, #ad_bot").remove();
$(".nav_top_2011, #header, #navigator").remove();
$(".p4course_target, .comment-box, .recommend-box, #csdn-toolbar, #tool-box").remove();
$("aside").remove();
$(".tool-box").remove();
$("main").css('display','content'); 
$("main").css('float','left'); 
window.print();

$("tool-box").remove();
})();
发布了349 篇原创文章 · 获赞 6 · 访问量 9636

猜你喜欢

转载自blog.csdn.net/qq_23929673/article/details/93030731