Closed
Bug 23020
Opened 26 years ago
Closed 26 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•26 years ago
|
Component: Javascript Engine → DOM Level 0
| Reporter | ||
Comment 1•26 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•26 years ago
|
Assignee: mccabe → vidur
Comment 2•26 years ago
|
||
Reassiging to DOM owner.
| Assignee | ||
Updated•26 years ago
|
Status: NEW → ASSIGNED
Whiteboard: [HAVE FIX]
Target Milestone: M13
| Assignee | ||
Comment 3•26 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•26 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
| Assignee | ||
Comment 4•26 years ago
|
||
Fixed on 1/14/2000.
You need to log in
before you can comment on or make changes to this bug.
Description
•