随笔分类 - JavaScript
摘要:最近遇到需要刷某网课,把视频进度条禁止掉了,下面是直接跳转的代码,到控制台运行即可 let video = document.querySelectorAll('video')[0]; // 选取第一个video节点 video.currentTime = video.duration - 3; /
阅读全文
摘要:<html> <head> <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.7.1/jquery.min.js"></script> <script src="https://cdn.bootcdn.net/ajax/libs/jSig
阅读全文
摘要:<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <script src="https://cdn.bootcdn.net/ajax/libs/echarts/5.4.3/echarts.min.js"></script> </head> <b
阅读全文
摘要:manifest.json "permissions": [ "storage" ] popup.js var data = { "url": "http://127.0.0.1" }; chrome.storage.local.set({ "data": data }, function(){ c
阅读全文
摘要:``` 姓名: 张三身份证: 44044019990217444X 打印 ``` ![image](https://img2023.cnblogs.com/blog/3130057/202308/3130057-20230807220842626-1558216644.png)
阅读全文
摘要:### 1.web端控制台代码 ``` const successCallback = function(data) { console.log(data); } var import_js = document.createElement('script'); import_js.setAttri
阅读全文
摘要:先定义以下函数,然后使用console.save()来保存 ``` (function (console) { console.save = function (data, filename) { let MIME_TYPE = "text/json"; if (!data) return; if
阅读全文
摘要:需要做一个扩展,拦截XMLHttpRequest,修改response里面部分值,查阅资料后一般是通过下面方法拦截 ``` let oldOpen = XMLHttpRequest.prototype.open; XMLHttpRequest.prototype.open = function(me
阅读全文
摘要:``` 姓名: 张三性别: 女身份证: 44044019990217444X体检日期: 20230530识别号: 2023053044044019990217444X 打印 ``` ![image](https://img2023.cnblogs.com/blog/3130057/202308/31
阅读全文
摘要:1. 脚本如下 需要引入jquery.min.js,FileSaver.min.js和jquery.wordexport.js(注意顺序) <!DOCTYPE html> <html> <head> <script src="https://cdn.bootcdn.net/ajax/libs/jqu
阅读全文
摘要:1. json转xlsx <html lang="zh"> <head> <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.3/jquery.min.js"></script> <script src="https://cdn.boo
阅读全文
摘要:1. popup.html <!DOCTYPE html> <html> <head> <meta http-equiv="content-type" content="text/html;charset=utf-8"> <meta name="viewport" content="width=de
阅读全文
摘要:var import_css = document.createElement("link"); import_css.setAttribute("rel","stylesheet"); import_css.setAttribute("href", "https://cdn.bootcdn.net
阅读全文