Last modified: 2008-09-13 06:02:08 UTC
Any links in the image's caption text become as if marked <nowiki>. For now, on emust strip links from ImageMap captions. For example:<br/> <imagemap> Image:EightTNOs.png|thumb|275px|The largest [[Trans-Neptunian object]]s that prompted the IAU's decision. rect 646 1714 2142 1994 [[Earth|The Earth]] desc none </imagemap>
The problem is that Parser::makeImage happens halfway through the multi-pass parsing normally, but those earlier passes haven't been run on ImageMap's text. So, no links, bold/italics, etc. Not sure what's the best way around this. Full subparse of the options text?
*** Bug 8924 has been marked as a duplicate of this bug. ***
Is there a default line in the real example (not shown in the text above)? I've noticed that the caption works if there is no default line and is overridden by the default otherwise. E.g. default [[Default page]] will override the caption on the first line's options.
What do you mean by "default line"?
As per input documentation: default This gives the default link, where no other regions are specified. The format is as I gave in the example: default [[Default page]] Clicking on the image where no area is defined with a shape will go to the default page.
Ah, you mean the default ''parameter''. No, specifying the default parameter changes nothing to the bug: the caption is still unparsed. On Wikipedia, anyway. Have you had experience otherwise?
Additional: The bug also means the image map will not accept parameters when embedded within a Template. It is thus impossible to build a template wrapper around an imagemap that would allow various defaults (image size, alignment, caption, etc.) to be passed in as parameters (named or default-numbered, doesn't matter). For example: <imagemap> Image:EightTNOs.png|thumb|275px|{{{caption|The largest [[Trans-Neptunian object]]s that prompted the IAU's decision}}} rect 646 1714 2142 1994 [[Earth|The Earth]] desc none </imagemap>
Created attachment 3622 [details] parser makeImage patch.txt Normal image captions are handled in two places: - wiki text rendering is done in internalParse() with the doAllQuotes() call - links are handled recursively in replaceInternalLinks() By moving/adding these calls into makeImage(), the caption rendering is done everytime that makeImage is used. This doesn't allow for wiki tables or headings(which do work in normal image links), for that the imagemap extension would have to be reworked. Produces same result in ParserTests as r22112. This solves the wiki text and links issues but template arguments cannot be used without fixing bug 2257 first.
Hi! i managed to resolve part of this bug with {{#tag}}, bypassing: Here's a working copy of imagemap {{#tag:imagemap| Image:It-{{{1}}}.png{{!}}40px{{!}}description default [[{{{1}}}]] desc none }}
Assigned to extension developer
This was fixed in r40684 / r40685.