Image Map and TinyMCE

Mark C - June 19, 2009 - 11:03

I'm trying to put an image map on my splashpage (which is created with Front Page Module. If I create the html in GIMP or Dreamweaver it works fine, but when I paste the html in to my html editor in Drupal (TinyMCE) it doesn't work.

It seems to be stripping the usemap="#map" section. I have turned off HTML Corrector and am using "Full HTML".

Here is my code:

<img src="/sites/default/files/frontpage.png" width="500" height="500" border="0" usemap="#map" />

<map name="map">
<!-- #$-:Image map file created by GIMP Image Map plug-in -->
<!-- #$-:GIMP Image Map plug-in by Maurits Rijk -->
<!-- #$-:Please do not edit lines starting with "#$" -->
<!-- #$VERSION:2.3 -->
<!-- #$AUTHOR:Mark Conroy -->
<area shape="poly" coords="248,457,253,443,255,431,262,422,268,411,287,408,306,406,321,410,324,421,327,429,324,443,316,454,307,463,296,472,279,475,263,477,255,473,250,469,248,461,248,457,250,456" href="http://www.markconroy.net/node" />
</map>

but it turns out as:

<img src="/sites/default/files/frontpage.png" width="500" height="500" border="0" />

<map name="map">
<!-- #$-:Image map file created by GIMP Image Map plug-in -->
<!-- #$-:GIMP Image Map plug-in by Maurits Rijk -->
<!-- #$-:Please do not edit lines starting with "#$" -->
<!-- #$VERSION:2.3 -->
<!-- #$AUTHOR:Mark Conroy -->
<area shape="poly" coords="248,457,253,443,255,431,262,422,268,411,287,408,306,406,321,410,324,421,327,429,324,443,316,454,307,463,296,472,279,475,263,477,255,473,250,469,248,461,248,457,250,456" href="http://www.markconroy.net/node" />
</map>

Any suggestions would be much appreciated.

Thanks,
Mark C.

_

WorldFallz - June 19, 2009 - 13:05

iirc, i believe you have to add usemap to the valid extended elements configuration for tinymce. If you do a search for "image map" over in the moxie code forums you should find the info you need.

_
Don't be a Help Vampire - read and abide the forum guidelines.
If you find my assistance useful, please pay it forward to your fellow drupalers.

semi-solution

Mark C - June 20, 2009 - 10:39

I have come up with a semi-solution. I turned off TinyMCE and did what I needed to do, then turned it on again. But now the blue border (link thing) is showing all the way around the image, as if I had just made the image a full link.

any ideas: it's at www.markconroy.net and only the blob at the end of the spill should be linked (which it is, but I need to get rid of the blue box).

Mark.
Thanks.

Regards,
Mark C.

_

WorldFallz - June 20, 2009 - 13:41

I believe you need to add border="0" to the img tag for the image map.

_
Don't be a Help Vampire - read and abide the forum guidelines.
If you find my assistance useful, please pay it forward to your fellow drupalers.

works

Mark C - June 20, 2009 - 18:13

It works with the border at "0". Thanks so much for the help.

mark.

Regards,
Mark C.

 
 

Drupal is a registered trademark of Dries Buytaert.