load a .js file

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • kidsoftuk

    load a .js file

    Hi

    I have a java script nav button bar where i preload images in each page
    header. I do i reference .js file with the preload scrip. Below is what
    i currently have


    <SCRIPT LANGUAGE="JAVAS CRIPT">
    <!--
    var image1 = new Image();
    image1.src = "http://mydomain/buttons/home1.gif";
    var image2 = new Image();
    image2.src = "http://mydomain/buttons/home1a.gif";
    var image3 = new Image();
    image3.src = "http://maydomain/buttons/about1.gif";
    var image4 = new Image();
    image4.src = "http://maydomain/buttons/about1a.gif";
    ..
    ..
    ..
    etc.


    Regards

    mark

  • McKirahan

    #2
    Re: load a .js file

    "kidsoftuk" <kidsoft@dsl.pi pex.com> wrote in message
    news:1102605940 .719919.150000@ c13g2000cwb.goo glegroups.com.. .[color=blue]
    > Hi
    >
    > I have a java script nav button bar where i preload images in each page
    > header. I do i reference .js file with the preload scrip. Below is what
    > i currently have
    >
    >
    > <SCRIPT LANGUAGE="JAVAS CRIPT">
    > <!--
    > var image1 = new Image();
    > image1.src = "http://mydomain/buttons/home1.gif";
    > var image2 = new Image();
    > image2.src = "http://mydomain/buttons/home1a.gif";
    > var image3 = new Image();
    > image3.src = "http://maydomain/buttons/about1.gif";
    > var image4 = new Image();
    > image4.src = "http://maydomain/buttons/about1a.gif";
    > .
    > .
    > .
    > etc.
    >
    >
    > Regards
    >
    > mark
    >[/color]

    Do you have a question?

    Anyway, you should change lines:
    <SCRIPT LANGUAGE="JAVAS CRIPT">
    <!--
    and
    -->
    </SCRIPT>
    to:
    <script type="text/javascript">
    and
    </script>


    Comment

    Working...