Web Developer External Data Files
Languages Assistance The Developer
Description
  • This script is universal in that it is a basic strand supported by all javascript supporting browsers, however the main difference in this script is the fact that you can put its call tags in multiple pages and then edit one file and it changes all of the pages where the call tags were. We use these frequently on our website because it makes simple things easier. An example of our use of this script would be to update the list of some files below the directories to the right. Instead of updating every page when a new page is added, we let javascript help us by writing it on all of them.
  •  
  • Difficulty: Easy, knowledge of HTML codes, and file manipulation.
Instructions
  1. Open a page or the pages where you want the script to be loaded onto
  2. Insert the following into these page(s):
    <script language="javascript" type="text/javascript" src="YOUR_FILE.js"></script>
  3. Open a word processor such as SimpleText or Notepad.
  4. Modify the following where HTML_TXT appears, and replace it with your own HTML code:
    document.write("HTML_TXT");
    Keep in mind that the following symbols are not permitted without placing a "\" in front of them within the document.write("");
    , " ( ) { } -
Additional Resources
HomeView IndexGo to Top

Creative Commons License
This work by http://webdeveloper.50webs.com is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.