In this post I will explain to you how to put together HTML, CSS and other languages you may want to make your website in.
We write code on our computers using a text editor or an IDE. You may read this article written by Codecademy: Where to write your code when you’re not on Codecademy
You may type out your code on any text editor, for example:
You will need to save each language file with its respective extension,
HTML - .html
CSS - .css
JavaScript - .js
Python - .py
Ruby - .rb
Just to mention a few
Save your main page as index.html
so it gets indexed as main page (home page)
Linking languages together - I’m sure you remember <link>
? We use it to link CSS to HTML. For example:
<link type="text/css" rel="stylesheet" href="stylesheet.css">
*Remember this goes in the <head> </head>
tags
Click for a refresher.
With JavaScript you use script tags:
<script type="text/javascript" src="script.js"></script>
Once we have typed out our code, linked it and saved it, we are ready to run it in our browser to test. Make sure your files are in one folder then right click on your HTML file and select - open with - choose your browser.
Yahooo its working !
Feel like making it live ? Then read Get your Website online