How To Add JavaScript And CSS File To HTML

I had no idea about JS and CSS when I started my blogging career. These are most common extensions which will require for making and designing your website. Here JS means JavaScript and CSS full form is Cascading Style Sheets. Today I won’t discuss about the definition of these two extensions and functions.

You will learn the adding method in your HTML.If you have any JavaScript or CSS codes you need to put the extension part to make it working.

When your file is ready now it’s time to upload it in your root folder. You can upload it from your website “HOSTING ACCOUNT”.

ADD it to HTML:
For adding it in HTML you have to put it with particular syntax that is for :

<script type=”text/JavaScript” src=”../../myscript.js”></script>
myscript.js = It would be your JavaScript file url

<link rel=”stylesheet” type=”text/css” href=”../../my.css?template=generic” />
my.css = It would be your CSS file url
You should place these links after <head> and close </head> when its done .For an example:

<script type=”text/javascript” src=”../../myscript.js”></script>
<link rel=”stylesheet” type=”text/css” href=”../../main.css?template=generic” />

Hope you can add the file. If you have any problem then please contact me or comment in below box.