forked from webjames/heroku-wordpress-svbtle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathscript.js
executable file
·31 lines (27 loc) · 840 Bytes
/
script.js
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
$(function() {
$(".double a.button").click(function(){
$(".double a.button").removeClass("checked");
$("input.RadioClass").attr("checked",null);
$(this).prev("input.RadioClass").attr("checked","checked");
$(this).addClass("checked");
});
$(".remove").click(function(){
var answer = confirm('Are you sure?');
return answer;
});
// preview in iframe on the edit page
$("a.button.preview").click(function(e){
// does the iframe exist already?
if ($("iframe.preview").length) {
// stop the event propogation
e.preventDefault();
// display the preview pane
$("div.preview").fadeIn(500);
}
});
// close preview
$("a.close").click(function(e){
e.preventDefault();
$("div.preview").fadeOut(500);
});
});