Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Oct 2003
    Location
    San Francisco
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    How do I install image rotating scripts in a separate .js file?

    I am using two different image rotating scripts in a mockup page. They both seem to work fine. However, now I need to install these scripts in a separate .js file, rather than keeping the scripts within the source code for the page (so I can create simplified Dreamweaver template pages). Can someone give me some help?

    Here’s the mockup page, with the two image rotating scripts embedded in the HTML. (both scripts call images in the lower left “Cocoon Latex” and “Snapshots”). I have already created a separate .js file which contains the navigation bar scripts:

    *URL EDITED BY MODERATOR*

    Thank you,

    Mark Burnley
    Last edited by joh6nn; 10-20-2003 at 06:14 AM.

  • #2
    Kor
    Kor is offline
    Red Devil Mod Kor's Avatar
    Join Date
    Apr 2003
    Location
    Bucharest, ROMANIA
    Posts
    8,478
    Thanks
    58
    Thanked 379 Times in 375 Posts
    first at all you have HTML errors on the page... You have 3 <head>...</head> lines, which is not necessary.

    Now... copy the code lines (except the specifications <SCRIPT LANGUAGE="JavaScript"> and </SCRIPT>) in a file using a ASCII editor (Dreamweaver, FrontPage... even Notepd is OK for this). Refere that file (extension .JS> in your head, like

    <HEAD>
    <script language="JavaScript" src="your_file.js"></script>
    </HEAD>

    If you say that all your scripts works ok together now, you may put all the scripts in a single js file, you may put them in different js files, it doesn't matter.
    KOR
    Offshore programming
    -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

  • #3
    Senior Coder joh6nn's Avatar
    Join Date
    Jun 2002
    Location
    72° W. 48' 57" , 41° N. 32' 04"
    Posts
    1,887
    Thanks
    0
    Thanked 1 Time in 1 Post
    um. dude. we've got rules about adult content, as do most places.

    we don't mind if that's what you're gonna do with the answer to your question, but posting that content here, or posting links to it, is against the rules that you agreed to when you joined.
    bluemood | devedge | devmo | MS Dev Library | WebMonkey | the Guide

    i am a loser geek, crazy with an evil streak,
    yes i do believe there is a violent thing inside of me.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •