How to Add External Javascript to html Page

In many cases we need to use Same Javascript functionality in more than one page of your website / Webpages. Instead of writing same Javascript code in every HTML, ASP, JSP or PHP page you need to customize the Javascript codes into a single file. Because if we add the raw javascript code in your website means will become too tough to maintain/ update the common javascript functionality, also it will lead to increase in page size too. So best option is to using javascript code from external file. Just add the below one line code into your html page/ document.
<script type="text/javascript" src="./js/sample.js"></scritp>

Related Topic Javascript Date Object Constructor with Examples
How to Include PHP in HTML File page
Confirm on Exist in Javascript
How to Disable Right Click on HTML Page
List of Common Mistakes Designing Website 2011   Privacy Policy  Terms of Service  Feedback