-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfancifymytext.js
33 lines (28 loc) · 1.14 KB
/
fancifymytext.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
function helloWorldAlert(){
//alert("Hello, world!");
document.getElementById("fancyText").style.fontSize = "24pt";
}
function fancy(){
if (fancy.checked = true){
//alert("Hello!")
document.getElementById("boring").checked = false;
document.getElementById("fancyText").style.fontWeight = "bolder";
document.getElementById("fancyText").style.textDecoration = "underline";
document.getElementById("fancyText").style.color = "blue";
}
}
function boring(){
if (boring.checked = true){
document.getElementById("fancy").checked = false;
document.getElementById("fancyText").style.fontWeight = "normal";
document.getElementById("fancyText").style.textDecoration = "none";
document.getElementById("fancyText").style.color = "black";
}
}
function moo(){
document.getElementById("fancyText").value = document.getElementById("fancyText").value.toUpperCase();
var str = document.getElementById("fancyText").value;
var parts = str.split(".");
str = parts.join("-Moo.");
document.getElementById("fancyText").value = str;
}