Alert boxes 10-12-2013, 11:34 AM
#1
I'm back to doing coding tutorials, I haven't done one since before DZ merged w/ Codecommunity so I'm a little rusty.
Let us begin, fellow peanuts~
What is Java?
Java is a basic necessity for a computer to run scripts specifically formatted .js. .JS is a javascript document, it requires Java and is used on almost every website. It does alert boxes, interactives, etc.
So sexy beef~
The script command in the html defines the script of java, php, ajax, or whatever script follows.
You could also link it by using the same sscript command with a src suffix.
Your-js-file-here
So what's the script, Duubz!?!
functionNameThis is the alert
It doesn't matter if it's it's own doc, or in the script command, either will work fine.
Linking it to HTML so it will actually pop up.
ValNameButton text
Just remember that capitals do make a difference. Copy this exactly, and edit accordingly to the cyan.
Note that the function name ( functionName() ) must be the same as in the js, and html. It's case sensitive too.
~ GnBA Duubz
Let us begin, fellow peanuts~
What is Java?
Java is a basic necessity for a computer to run scripts specifically formatted .js. .JS is a javascript document, it requires Java and is used on almost every website. It does alert boxes, interactives, etc.
So sexy beef~
Code:
<Html>
<script>The script command in the html defines the script of java, php, ajax, or whatever script follows.
You could also link it by using the same sscript command with a src suffix.
Code:
<script src="Code:
.js"></script>So what's the script, Duubz!?!
Code:
functionCode:
()
{
alert("Code:
");
}It doesn't matter if it's it's own doc, or in the script command, either will work fine.
Linking it to HTML so it will actually pop up.
Code:
<button type="button" onclick="functionName()" value="Code:
">Code:
</button>Just remember that capitals do make a difference. Copy this exactly, and edit accordingly to the cyan.
Note that the function name ( functionName() ) must be the same as in the js, and html. It's case sensitive too.
~ GnBA Duubz
![[Image: BXqGARG.png]](https://i.imgur.com/BXqGARG.png)









![[+]](https://sinister.li/images/modern/collapse_collapsed.png)






![[Image: signature.png]](https://ctrlhub.co/style/images/signature.png)


![[Image: 5IN9GdK.png]](http://i.imgur.com/5IN9GdK.png)










![[Image: 7ajmN5P.jpg]](https://i.imgur.com/7ajmN5P.jpg)