[Typo3] Imagemaps with Javascript window open

Peter Klein peter at umloud.dk
Wed Mar 2 16:20:33 CET 2005


"Jan Wulff" <messages at janwulff.de> skrev i en meddelelse 
news:mailman.1.1109774142.26890.typo3-english at lists.netfielders.de...
> Hi,
>
> I'm just wondering if it is possible to create area tags (for an imagemap)
> including the Javascript window open function. This is easily possible for
> 'a' tags for example by this:
> 10 = TEXT
> 10.typolink.parameter.field = tv_link_field
>
> If tv_link_field was set in the page header to '6 123x456', this will
> create an 'a' tag like this:
> <a href="#"
> onclick="vHWin=window.open('index.php?id=6','FEopenLink','width=123,height=456');vHWin.focus();return
> false;">Test</a>
>
> As far as I can see, I have to build the area tag for imagemaps by myself.
> If so, I have to get access to the onclick attribute of the typolink, but 
> I
> can't find any option to do this. I could just take the 'a' tag and try to
> cut of the beginning and ending characters, till only the onclick 
> attribute
> is left, but because the length of the tag may change, I can't use
> stdWrap.substr.
>
> The only option I can see at this moment, is to create three input fields,
> one for the target page, one for the width and one for the height of the
> new window and build the Javascript by myself with Typoscript, but that
> feels to much like a dirty hack for me. If Typo3 already offers this
> function for 'a' tags, it should be possible to use it for area tags, too.
>

I don't think it's possible using the "IMGMENU" menu object, which only has 
a limited number of properties compared to TMENU/GMENU.
And unfortunatly it doesn't have "IProcFunc" which would be just what you 
need.

Another thing missing in "IMGMENU" is the ability to make CSS based 
rollovers.. :(

-- 
Peter Klein/Umloud Untd 





More information about the TYPO3-english mailing list