-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjquery_slide_toggle.html
More file actions
65 lines (65 loc) · 1.57 KB
/
jquery_slide_toggle.html
File metadata and controls
65 lines (65 loc) · 1.57 KB
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
<html>
<head>
<title>jQuery - Slide Toggle</title>
<style>
body {
margin: 0 auto;
padding: 0;
width: 200px;
text-align: center;
}
a:hover{
-webkit-box-shadow: 0 0 8px #FFD700;
-moz-box-shadow: 0 0 8px #FFD700;
box-shadow: 0 0 8px #FFD700;
cursor: pointer;
}
.panel {
background: #ffffbd;
background-size: 90% 90%;
height: 300px;
display: none;
font-family: garamond, times-new-roman, serif;
}
.panel p {
text-align: center;
}
.slide {
margin: 0;
padding: 0;
border-top: solid 2px #cc0000;
}
.pull-me {
display: block;
position: relative;
right: -25px;
width: 150px;
height: 20px;
font-family: arial, sans-serif;
font-size: 14px;
color: #ffffff;
background: #cc0000;
text-decoration: none;
-moz-border-bottom-left-radius: 5px;
-moz-border-bottom-right-radius: 5px;
border-bottom-left-radius: 5px;
border-bottom-right-radius: 5px;
}
.pull-me p {
text-align: center;
}
</style>
<script src="js/jquery.min.js"></script>
<script>
$(document).ready(function() {
$('.pull-me').click(function() {
$('.panel').slideToggle('slow');
});
});
</script>
</head>
<body>
<div class="panel"><br><br><p>Huzzah!</p></div>
<p class="slide"><a href="#" class="pull-me">Slide Up/Down</a></p>
</body>
</html>