Javascript doesn't work in Firefox

T

The87Boy

Hey
I have a problem with a Javascript, which doesn't works in Firefox
You can have a mouse over the 2 first pictures, but after the second
picture has moved over the screen, nothing is happening when you move
the mouse over the slideshow
The source code is here:
http://the87boy.dk/Slideshow.html

What could be wrong?
 
R

RobG

Hey
I have a problem with a Javascript, which doesn't works in Firefox
You can have a mouse over the 2 first pictures, but after the second
picture has moved over the screen, nothing is happening when you move
the mouse over the slideshow
The source code is here:http://the87boy.dk/Slideshow.html

What could be wrong?

A lot. In Firefox I see nothing at all, I didn't bother to check with
IE.

Some tips:

- Don't use browser detection, use feature detection
- Don't use eval - it is a good indication that you don't understand
basic javascript
- Don't use large numbers of global variables, each one you use
increases the chance of a collision with other code

Anyhow, your issue is likely related to your invalid HTML:

<div id='adv' width=&{scrollerwidth}; height=&{scrollerheight};
bgColor=&{scrollerbgcolor}; visibility=hide>


Your doctype claims HTML 4 strict, check with a validator - there are
40 errors, nearly all of them significant:

<URL: http://validator.w3.org/check?uri=http://the87boy.dk/Slideshow.html

<img src='Pics/Party-Nord.png' width=&{scrollerwidth};
height=&{scrollerheight}; />

Don't use XML markup when your doctype is HTML.
 
T

The87Boy

A lot. In Firefox I see nothing at all, I didn't bother to check with
IE.

Some tips:

- Don't use browser detection, use feature detection
- Don't use eval - it is a good indication that you don't understand
basic javascript
- Don't use large numbers of global variables, each one you use
increases the chance of a collision with other code

Anyhow, your issue is likely related to your invalid HTML:

<div id='adv' width=&{scrollerwidth}; height=&{scrollerheight};
bgColor=&{scrollerbgcolor}; visibility=hide>

Your doctype claims HTML 4 strict, check with a validator - there are
40 errors, nearly all of them significant:

<URL:http://validator.w3.org/check?uri=http://the87boy.dk/Slideshow.html>

<img src='Pics/Party-Nord.png' width=&{scrollerwidth};
height=&{scrollerheight}; />

Don't use XML markup when your doctype is HTML.

I know my problem is DOM, because I can see the rendered code, that
the a-tag only goes twice
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,280
Latest member
BGBBrock56

Latest Threads

Top