-
Notifications
You must be signed in to change notification settings - Fork 0
/
custom.js
95 lines (64 loc) · 2.08 KB
/
custom.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
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
86
87
88
89
90
91
92
93
94
95
$(document).ready(function () {
$(".yazilar").append("hamo");
//$("button").css({backgroundColor: "red"})
$("#goster").css({ color: "blue"})
$("li:even").css({ backgroundColor: "red" });
$("li:odd").css({ backgroundColor: "blue" });
$("li:nth-child(3").css({backgroundColor: "purple" });
$("button:first-child").css({backgroundColor:"red"});
$("button:last-child").css({backgroundColor:"yellow"});
var yazilar = $(".yazilar")
$("#gizle").click(function () {
$(yazilar).hide(2000);
});
$("#goster").click(function () {
$(yazilar).show(500);
});
$("#goster-gizle").click(function () {
$(yazilar).toggle(1000);
});
$("#acil-kapan").click(function () {
yazilar.slideUp().slideDown();
});
$("#eleman-ekle").click(function () {
yazilar.append("hamo");
yazilar.prepend("Hamo");
});
$("#eleman-sil").click(function () {
$("li:first-child").remove();
});
$("#sinif-ekle").click(function () {
yazilar.addClass("ekle");
});
$("#sinif-kaldir").click(function () {
yazilar.removeClass("ekle");
});
$("#sinif-degis").click(function () {
yazilar.toggleClass("ekle");
});
//******************************************************************************************************************************** */
var kutu1 = $(".kutu1");
var kutu2 = $(".kutu2");
var poz1 = kutu1.position();
var sol1 = poz1.left;
var poz2 = kutu2.position();
$("#anim-basla").click(function () {
kutu1.css({position:"relative"});
while (sol1 <= 1100 ) {
kutu1.animate({
left:"+=20"
});
sol1 +=50;
}
});
var zaman=setInterval(kac,1000);
function kac () {
var d = new Date();
var saat = d.getHours();
var dakika = d.getMinutes();
var saniye = d.getSeconds();
$(".saat").text(saat);
$(".dakika").text(dakika);
$(".saniye").text(saniye);
}
});