Your First $1000 online (2014)
Chapter 8: Making The Hello World App With HTML Texts
“Talk is cheap. Show me the code.”
- Linus Torvalds
Making the Hello World App will help you see how the HTML texts can be used to make certain apps.
Before you resume you need to know about JavaScript. You have to use JavaScript with HTML and that is precisely what you will do here.
1. Launch Notepad to make your HTML file.
2. Type the following into the document:
<!DOCTYPE HTML> <html> <head> <title>JavaScript Hello World</title> </head> <body> <h1>JavaScript Hello World Example</h1> </body> </html> |
3. Save the file by the following name: test.html. Click on All Files on the dropdown menu in front of “Save as type”.
By following these steps you have simply created a framework for the Hello World app, using the HTML template. You don’t have to be an expert to do so because these steps are quite easy to follow.
Once this part is done you will add the JavaScript program by typing the following in front of the <h1> tag:
<script> <alert(“Hello World!”) <script> |
If you were to insert this into the web browser you would see this:
JavaScript has absolutely nothing to with Java itself. You are only using the HTML text to insert JavaScript into the structured document.
Conclusion
This book covers the essentials on HTML and the basics you need to know about it. I hope you enjoyed reading and learning how to code from scratch.
Thank you, for downloading the book once again!