DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2004

    remote image swap with mouse over text


    I have been trying to creat a mouse over effect where i scroll over several text headings, and an image in a fixed location changes with each product heading i am over.

    Is there a way i can do this hich will work in most browsers, i have it working at the moment in apple's safari browser and the page is www.canondigitalcentre.com

    it will not work in IE. i would appreciate any advice you can give, i am using dreamweaver MX 2004 mac


  2. #2
    Join Date
    Oct 2004
    you are working with javascript, not Java. Java is a programming language, like C or BASIC. javascript is a scripting language, which means that it isn't compiled before it's run. javascript is much simpler than Java, too.

    i viewed source on your page anyways, because i recently learned javascript, too.

    first off, you're going to want some alt text in your img's. the last thing a user wants to see is a red X instead of a camera, without any explanation.

    secondly, how big are these img's? i've been on the site for almost a whole minute and it's still transferring data.
    i assume your image preloader is getting bogged down. have you thought about having one page for each section of the list of cameras? or using thumbnails? frames would work, but they're a pain in the butt, not to mention less than lovely to browse through, either.

    AHA! i just found your problem.
    NS [including Mozilla, Firefox and, i assume, all apple browsers] uses the method document.GetElementById(objname) and the property document.layers
    IE uses only the document.all property.

    your script, when run in any browser that doesn't support the document.GetElementById(name) method, can't find the img.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.