-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
executable file
·85 lines (71 loc) · 2.18 KB
/
index.php
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
<html>
<head>
<style type="text/css">
.button {
min-height: 100px;
min-weight: 100px;
padding: 10px 10px;
background-color: white;
color: black;
font-size: bolder;
font-color: #3B2E2E;
border-radius: 30px;
}
.content {
background-color: #DAECF6;
border-color: #C4DDEF;
border-style: solid;
height: 100px;
width: auto;
margin: 20px 10px 20px 20px;
padding: 20px 10px 20px 20px;
}
.bookmarklet {
margin-bottom: 20px;
}
a:visited {
font-color: #3B2E2E;
text-decoration: none;
}
a {
font-color: #3B2E2E;
text-decoration: none;
}
</style>
</head>
<body>
<div class="content">
<?php if(isset($_GET['url'])): ?>
<div class="bookmarklet">
<a class="button" href="javascript:var script = document.createElement('script');
script.src = '<?php echo $_GET['url'] ?>';
script.type = 'text/javascript';
document.getElementsByTagName('head')[0].appendChild(script);
void(0);"><?php if (isset($_GET['name'])) echo $_GET['name']; else echo $_GET['name']; ?></a>
<span> <-------- DRAG THIS LINK AND MOVE IT TO YOUR BOOKMARK BAR </span>
</div>
<?php endif; ?>
<div>
<?php if(isset($_GET['url'])): ?>
Note: This bookmarklet inject in your page script from <?php echo $_GET['url'] ?>
<?php else: ?>
Use this form to create injecting bookmarklet
<form id="form" method='get'>
<div>Url of script to be injected by click on bookmarklet: <input id='urlRawText' name='url' type='text'></div>
<div>Bookmarklet name (optional) : <input type='text' name='name'></div>
<div><input id="submitButton" type="submit" value="bookmarklet it!"></div>
</form>
<?php endif; ?>
</div>
</div>
<div>
<h2><a href="http://en.wikipedia.org/wiki/Bookmarklet">What is bookmarklet?</a></b>
</div>
<p>
TODO: browser sensitive help (as in modern days browser the bookmark bar is invisible by default
</p>
<p>
TODO: animovany obrazek nebo youtube video s ukazkou pretazeni a kliknuti
</p>
</body>
</htm>