Closed
Bug 23020
Opened 25 years ago
Closed 25 years ago
src property of javascript image object not setting properly
Categories
(Core :: DOM: Core & HTML, defect, P3)
Tracking
()
RESOLVED
FIXED
M13
People
(Reporter: rwillcox, Assigned: vidur)
References
()
Details
(Whiteboard: [HAVE FIX])
Changing the src property of an image object in the document images array replaces the target image with the literal text string from the argument passed as the new source.
Reporter | ||
Updated•25 years ago
|
Component: Javascript Engine → DOM Level 0
Reporter | ||
Comment 1•25 years ago
|
||
After additional testing, I've determined that the above bug is due to the Mozilla js engine's inability to resolve relative paths for dynamically assigned image sources when the images in question are within a servlet driven document. Below is the exact image rollover code used in the above example URL (it works fine when not in a servlet driven document): function swapImg() { if(!document.images) return; var args = swapImg.arguments; for(i=0; i < args.length; i+=2){ document.images[args[i]].src = args[(i + 1)]; } }
Updated•25 years ago
|
Assignee: mccabe → vidur
Comment 2•25 years ago
|
||
Reassiging to DOM owner.
Assignee | ||
Updated•25 years ago
|
Status: NEW → ASSIGNED
Whiteboard: [HAVE FIX]
Target Milestone: M13
Assignee | ||
Comment 3•25 years ago
|
||
The problem is that the src setting is being done with a relative URL and we aren't taking into account the BASE tag when resolving the URL. I have a fix waiting in my tree.
Assignee | ||
Updated•25 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 4•25 years ago
|
||
Fixed on 1/14/2000.
You need to log in
before you can comment on or make changes to this bug.
Description
•