-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
47 lines (44 loc) · 5.34 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8'>
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<link href='https://fonts.googleapis.com/css?family=Architects+Daughter' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="stylesheets/stylesheet.css" media="screen" />
<link rel="stylesheet" type="text/css" href="stylesheets/pygment_trac.css" media="screen" />
<link rel="stylesheet" type="text/css" href="stylesheets/print.css" media="print" />
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<title>edit WIRED bookmarklets</title>
</head>
<body>
<header>
<div class="inner">
<h1>Bookmarklets to directly edit articles in WordPress and Copilot.</h1>
</div>
</header>
<div id="content-wrapper">
<div class="inner clearfix">
<section id="main-content">
<p>Add this bookmarket to edit WIRED copilot articles, bundles, contributors, galleries, previews and reviews.
Note in Firefox, you can't drag and drop. But you can drag and drop the bookmarket from Chrome to Firefox ¯\_(ツ)_/¯</p>
<div class="wrap">
<button class="tip">
<a href="javascript:(function()%7Bvar%20path%20%3D%20window.location.pathname.split(%22%2F%22)%3Bvar%20cpID%20%3D%20path%5B4%5D%20%7C%7C%20%22%22%3Bvar%20p%20%3D%20path%5B3%5D%20%7C%7C%20%22%22%3Bvar%20o%20%3D%20cpID%3Bvar%20q%20%3D%20%22articles%22%3Bvar%20n%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2Farticles%2F%22%3Bif%20(%20p%20%3D%3D%3D%20%22gallery%22%20)var%20q%20%3D%20%22galleries%22%3Belse%20if%20(%20p%20%3D%3D%3D%20%22bundle%22%20)var%20q%3D%22bundles%22%3Belse%20if%20(%20p%20%3D%3D%3D%20%22review%22%20)var%20q%3D%22reviews%22%3Belse%20if%20(%20p%20%3D%3D%3D%20%22article%22%20)var%20q%3D%22articles%22%3Belse%20if%20(%20p%20%3D%3D%3D%20%22contributor%22%20)var%20q%3D%22contributors%22%3Belse%20var%20q%20%3D%20p%3Bif%20((cpID.length%20%3D%3D%3D%2024%20))%20%7Bn%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2F%22%20%2B%20q%20%2B%20%22%2F%22%20%2B%20o%3Bwindow.open(n)%3B%7D%20else%20if%20(document.querySelector(%22meta%5Bname%3D'content-type'%5D%22).getAttribute(%22content%22)%20%3D%3D%3D%20%22contributor%22)%20%7Bvar%20c%20%3D%20document.querySelector(%22meta%5Bname%3D'id'%5D%22).getAttribute(%22content%22)%3Bn%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2Fcontributors%2F%22%20%2B%20c%3Bwindow.open(n)%3B%7D%20else%20if%20(document.querySelector(%22meta%5Bname%3D'content-type'%5D%22).getAttribute(%22content%22)%20%3D%3D%3D%20%22gallery%22)%20%7Bvar%20c%20%3D%20document.querySelector(%22meta%5Bname%3D'id'%5D%22).getAttribute(%22content%22)%3Bn%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2Fgalleries%2F%22%20%2B%20c%3Bwindow.open(n)%3B%7D%20else%20if%20(document.querySelector(%22meta%5Bname%3D'content-type'%5D%22).getAttribute(%22content%22)%20%3D%3D%3D%20%22category%22)%20%7Bvar%20c%20%3D%20document.querySelector(%22meta%5Bname%3D'id'%5D%22).getAttribute(%22content%22)%3Bn%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2Fbundles%2F%22%20%2B%20c%3Bwindow.open(n)%3B%7D%20else%20if%20(document.querySelector(%22meta%5Bname%3D'content-type'%5D%22).getAttribute(%22content%22)%20%3D%3D%3D%20%22homepage%22)%20%7Bvar%20c%20%3D%20document.querySelector(%22meta%5Bname%3D'id'%5D%22).getAttribute(%22content%22)%3Bn%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2Fbundles%2F%22%20%2B%20c%3Bwindow.open(n)%3B%7D%20else%20if%20(document.querySelector(%22meta%5Bname%3D'content-type'%5D%22).getAttribute(%22content%22)%20%3D%3D%3D%20%22review%22)%20%7Bvar%20c%20%3D%20document.querySelector(%22meta%5Bname%3D'id'%5D%22).getAttribute(%22content%22)%3Bn%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2Freviews%2F%22%20%2B%20c%2Cwindow.open(n)%3B%7D%20else%20if%20(document.querySelector(%22meta%5Bname%3D'content-type'%5D%22).getAttribute(%22content%22)%20%3D%3D%3D%20%22article%22)%20%7Bvar%20c%20%3D%20document.querySelector(%22meta%5Bname%3D'id'%5D%22).getAttribute(%22content%22)%3Bn%20%3D%20%22https%3A%2F%2Fcopilot.aws.conde.io%2Fwrd%2Farticles%2F%22%20%2B%20c%2Cwindow.open(n)%3B%7Dconsole.log(%22********BookMarklet****************%22)%3Bconsole.log(%22meta%3A%20%22%20%2B%20c)%3Bconsole.log(%22path%3A%20%22%20%2B%20n)%3Bconsole.log(%22path%202%3A%20%22%20%2B%20p)%3Bconsole.log(%22************************************%22)%7D)()">WIRED CoPilot Edit v0.5</a>
<span class="left">Drag and drop to your bookmark toolbar</span>
</button>
</div>
<div class="wrap">
<button class="tip">
<a href="javascript:void%20function(){(function(){var%20o=document.querySelector(%22body%22).getAttribute(%22class%22),t=/postid-(\d+)/,i=t.exec(o)[1],n=%22/wp-admin/post.php%3Fpost=%22+i+%22%26action=edit%22,c=window.location.protocol+%22//%22+window.location.host+n;window.open(c)})()}();">WIRED Wordpress Edit Bookmarklet</a>
<span class="left">Drag and drop to your bookmark toolbar<span class="nub"></span>
</span>
</button>
</div>
</section>
</div>
</div>
</body>
</html>