Side navigation
#6679 closed bug (invalid)
Opened June 16, 2010 10:58AM UTC
Closed October 03, 2010 02:14AM UTC
Dynamic area map fails on Safari/Chrome
Reported by: | adyzah | Owned by: | |
---|---|---|---|
Priority: | undecided | Milestone: | 1.4.3 |
Component: | manipulation | Version: | 1.4.2 |
Keywords: | area map safari chrome | Cc: | |
Blocked by: | Blocking: |
Description
NOT WORKING code follows:
<div id="d"></div>
...
<script>
$(document).ready(function() {
$('#d').append('<img id="i" usemap="#m" style="border:1px solid #000;width:400px;height:200px" src="data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==" />');
$('#d').append('<map name="m" id="m"></map>');
$('#m').append('<area coords="0,0,400,200" shape="rect" href="javascript:void(0)">');
});
</script>
WORKING code follows:
...
change the map creation (using append) with basic stuff:
var oMap = document.createElement('map');
oMap.setAttribute('id', 'm');
oMap.setAttribute('name', 'm');
document.getElementById('d').appendChild(oMap);
Hints/notes:
1. It's not because dynamic IMG or inline data of IMG
2. It's not because order of append call on IMG vs MAP
3. Strangely, the code works with jQuery 1.3.2 (both using the workaround with the append(<map><area></map>).contents()) or just plain innerHTML
Thanks,
Adrian
Attachments (0)
Change History (1)
Changed October 03, 2010 02:14AM UTC by comment:1
need: | Review → Test Case |
---|---|
priority: | → undecided |
resolution: | → invalid |
status: | new → closed |
I've tested your original code using:
jQuery 1.4.2
Safari 5.02
FireBug Light for Safari
and the output appears to be exactly what I see when I execute the original code in the FireFox 3.6.10.
Could you re-submit your ticket with information on what versions of Safari and Chrome you're seeing this behavior on?