Skip to content

Instantly share code, notes, and snippets.

package main
import (
"context"
"flag"
"fmt"
"log"
"net/http"
"os"
// 比较偷懒,采取半人工操作
// 删除回答
// 在这个页面上 https://www.zhihu.com/people/shawphy/answers ,打开chrome控制台,粘贴下面代码,一次删20条
var xhr = new XMLHttpRequest();
document.querySelectorAll(".AnswerItem>meta[itemprop='url']").forEach(function(e,i){
setTimeout(function() {
xhr.open("DELETE",e.content.replace(/question\/\d+\/answer/,"api/v4/answers"));
xhr.send();
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>17天搞定GRE单词背诵计划时间表生成器</title>
<style type="text/css">
a{text-decoration: none;color:#39f; }
body{width: 988px; margin: 0 auto;}
th{text-align: right; font-size: 14px; color: #666;width: 100px;}
@shawphy
shawphy / baidumap.html
Last active May 3, 2017 15:22
在百度地图上标出对应地址的红点和名字。输入格式为姓名<tab>地址。从excel复制过来为宜。
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<title>批量地址</title>
<style type="text/css">
body, html,#allmap {width: 100%;height: 100%;overflow: hidden;margin:0;}
#l-map{height:100%;width:78%;float:left;border-right:2px solid #bcbcbc;}
#r-result{height:100%;width:20%;float:left;}