-
Notifications
You must be signed in to change notification settings - Fork 12
/
copyright-year.js
61 lines (43 loc) · 1.32 KB
/
copyright-year.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
/**
* xgqfrms 2017.01.01
* @copyright xgqfrms 2017-2050
* @version 1.1.1
* @link https://cdn.xgqfrms.xyz/plugins/getfullyear.js
*/
const copyRightYear = () => {
let copyYear = Symbol();
copyYear = new Date().getFullYear();
const spanYear = document.getElementById('spanYear');
spanYear.style.background = "yellow";
spanYear.style.color = "#000";
spanYear.innerHTML = `Copyright © ${copyYear} - 2050 xgqfrms`;
return spanYear;
}
window.onload = copyRightYear();
/*
https://cdn.xgqfrms.xyz/plugins/getfullyear.js
*/
const justForTesting = () => {
const xcpy20xx = document.getElementById('xcpy20xx');
let xcpy = new Date().getFullYear();
xcpy20xx.innerHTML = `copyright © xgqfrms ${xcpy}`;
xcpy20xx.style.color = "rgba(0,255,0,0.7)";
xcpy20xx.style.background = "rgba(0,0,0,1)";
console.log(xcpy);
return xcpy20xx;
}
/*
document.nodeValue
document.textContent
# HTML DOM
## HTML DOM Document Object
http://www.w3schools.com/jsref/dom_obj_document.asp
## HTML DOM Element Object
http://www.w3schools.com/jsref/dom_obj_all.asp
## HTML DOM Attribute Object
http://www.w3schools.com/jsref/dom_obj_attributes.asp
## HTML DOM Style Object
http://www.w3schools.com/jsref/dom_obj_style.asp
## HTML DOM Events
http://www.w3schools.com/jsref/dom_obj_event.asp
*/