server-side image maps ismap coordinates are wrong for positioned images.

VERIFIED WORKSFORME

Status

()

Core
Layout: Images
VERIFIED WORKSFORME
12 years ago
10 years ago

People

(Reporter: Jon Barnett, Unassigned)

Tracking

({regression})

Trunk
x86
Windows XP
regression
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(1 attachment)

(Reporter)

Description

12 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) Gecko/20051111 Firefox/1.5
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) Gecko/20051111 Firefox/1.5

If the image's CSS position is "static" the coordinates are fine.  If the image is relatively or absolutely positioned somewhere else, the coordinates are relative to the image's original position as if it were "static".

Reproducible: Always

Steps to Reproduce:
1.View testcase.
2.Mouse over the image
3.Notice that the status bar shows the wrong coordinates in the URL.

Actual Results:  
Coordinates relative to the image's original "static" position.

Expected Results:  
Coordinates relative to the image, regardless of position.

http://forums.mozillazine.org/viewtopic.php?t=352305 
That thread went into more detail.  It worked properly in Fx 1.0.7.
(Reporter)

Comment 1

12 years ago
Created attachment 205408 [details]
Testcase

Comment 2

12 years ago
I can confirm this bug. I can also add that for inputs with "postion:relative;" it appears to calculate the coordinates as if the image was originally located in the top-left corner of the canvas, adding on the offset from this position to the actual position of the input element.

Comment 3

12 years ago
(In reply to comment #2)
> I can confirm this bug.

Also, this bug seems to affect <input type="image" /> too.
Assignee: jdunn → nobody

Comment 4

11 years ago
I have a version of this bug in seamonkey 1.1.2 and k-meleon 1.1 . Was not present in mozilla 1.7.x

Absolutely positioned images with ismap return mouse position in relation to the whole page, ie topleft corner of window. 

{{style def}}
.map {  position:absolute; border:0; width:500px; height:500px; margin:0;}

{{html}}
<a href="mapview.php?sf=50&coords=017000-015000">
  <img src="maps/maps-250/015000/017000.jpg" class="map" 
   ismap="ismap" style="left:-80px;top:-280px;" />
</a>

HELP this is a PITA!!


Comment 5

11 years ago
This bug exists in firefox 2.0 for me, but not in the nightly trunk builds. The fix will be in firefox 3, but almost certainly won't be in any 2.x release.

I don't know exactly what fixed it, so -> WORKSFORME
Status: UNCONFIRMED → RESOLVED
Last Resolved: 11 years ago
Keywords: regression
Resolution: --- → WORKSFORME

Comment 6

10 years ago
This bug IS NOT RESOLVED. 

The latest 2.0.0.11 Firefox still has it.

I have a  whole batch of browsers that are hanging back at Mozilla 1.7.13 due to this one bug. 

Take a look at the test case: 
https://bugzilla.mozilla.org/attachment.cgi?id=205408
Duplicate of this bug: 387846
It's not resolved in Firefox 2.0.0.x, which at this point is only getting fixes for crashes and security issues, and is fixed in the builds which will be Firefox 3.0 before too long. As dolphinling said, in comment 5.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.