Template talk:Infobox islands/Archive 2

Please add "Infobox mapframe" item
Hi, please add Infobox mapframe item by inserting this code: Add it exactly after the item named image3. Thanks, Hooman Mallahzadeh (talk) 18:50, 28 November 2023 (UTC)
 * Red information icon with gradient background.svg Not done: please make your requested changes to the template's sandbox first; see WP:TESTCASES. Many mapframe-related parameters will need to be added to the unknown parameter check as well. You should be able to copy them from a similar template. – Jonesey95 (talk) 21:11, 28 November 2023 (UTC)
 * I used the above code at Template:Infobox islands/sandbox and it works properly for these Infoboxes:

No parameters need to be added the same as in other usages of this code, for example in Template:Infobox waterfall and the red line indicators are appeared in the original article because it refers to the WikiData item to recognize the correct map of it. Thanks,
 * Notice when you preview these infoboxes, you see "Preview warning: Page using Template:Infobox islands with unknown parameter "mapframe-zoom"". You'll get the same error with infobox waterfall; it turns out to be a bad example to copy from. See the documentation at Module:Infobox mapframe for what needs to be added to the unknown parameter check at the bottom of the template code. – Jonesey95 (talk) 05:39, 29 November 2023 (UTC)


 * We don't need the parameter "mapframe-zoom" for this template at all, and this error message has been removed in my new edition of this template usages, i.e. the first line of these usages are removed. In fact, by inheritance law, this parameter is inherited to the "Module:Infobox mapframe". This parameter is not required for the template, but if we use it, it would inherit to this module invoking. Hooman Mallahzadeh (talk) 05:59, 29 November 2023 (UTC)
 * @Jonesey95 Sorry! The problem resolved this way. Thanks, Hooman Mallahzadeh (talk) 06:58, 29 November 2023 (UTC)
 * @Jonesey95 At least in Arabic and Persian, these codes that produce map are used. English does need it too. Hooman Mallahzadeh (talk) 07:57, 29 November 2023 (UTC)
 * The above makes little sense, but I have implemented this edit request, along with the parameters necessary to make the unknown parameter check work properly. – Jonesey95 (talk) 13:29, 29 November 2023 (UTC)
 * @Jonesey95 Again like our discussion in Template:Infobox zoo and in Template_talk:Infobox_mapframe about "default behavior of displaying red lines in the map", I really suppose to add this parameter
 * This way it shows red lines by default, unless we unable it. Thanks again, Hooman Mallahzadeh (talk) 05:20, 30 November 2023 (UTC)
 * As with that discussion, I don't understand what you are saying, or what you are asking for. Please link to some example pages that illustrate a problem or something that you want to change. – Jonesey95 (talk) 05:39, 30 November 2023 (UTC)
 * @Jonesey95 For example in the article "قشم" in Persian Wikipedia, and in the Infobox part, there exists a map which has red colored island border indicators, but in its English edition (which is "Qeshm") and in the Infobox part and in the fourth image (map) from top (the last one), there exists a map in which red colored island border indicators are not shown.
 * This happens because the default value of showing border of islands is set to "no". The above code (parameter) changes the default value to "yes". Hooman Mallahzadeh (talk) 06:59, 30 November 2023 (UTC)
 * Thanks for the link. I have added the above setting to the code and fixed the code pasted above so that the #if test for pushpin_map actually works. – Jonesey95 (talk) 15:52, 30 November 2023 (UTC)
 * @Jonesey95 Your edit seems reasonable. Hooman Mallahzadeh (talk) 16:57, 30 November 2023 (UTC)
 * @Jonesey95 After a few days, I found that your edit is not good. In fact, "pushin maps" and Mapframe are used for different purposes.
 * Pushin_Map display the location of island from a country or in a continent or the world.
 * Mapframe is used to show the inside map of an island
 * So, they are used for totally different purposes. One is for outside of an island and the other is used for inside of an island. Therefore, exclusive usage of them (as your code displays them exclusively) is not correct.
 * Non exclusive usage is used for example in Tehran article, and in its Infobox, both of "mapframe map" and "pushin map" are used together to show different aspects of a city. Thanks, Hooman Mallahzadeh (talk) 08:47, 4 December 2023 (UTC)
 * I simply implemented your proposed edit, after fixing a typo. – Jonesey95 (talk) 13:59, 4 December 2023 (UTC)
 * @Jonesey95 No, your edit implements "show pushin or mapframe exclusively". This is not correct becuase it is exclusive. The correct code will be:
 * Exacly taken from Template:Infobox zoo. Some codes in if statement is redundant here. Please correct that. Hooman Mallahzadeh (talk) 16:41, 4 December 2023 (UTC)
 * That code is clearly broken. The if statements in the two lines test for different parameters, and pushpin map is not valid. Can you please test your code in the sandbox? – Jonesey95 (talk) 16:50, 4 December 2023 (UTC)
 * @Jonesey95 The correct code is sandboxed at: Template:Infobox islands/sandbox
 * I have tested it at Qeshm Island by temporarily changing the main template to sandbox version of it, in this article. Hooman Mallahzadeh (talk) 17:18, 4 December 2023 (UTC)
 * I don't see a "Location in..." autocaption there, and the code is still wrong as I described above. Please continue testing. (Edited to add: I am not sure that autocaption works anywhere. I have copied the live template code to the sandbox, which is the first step before adjusting the sandbox. Please continue testing from that point.) – Jonesey95 (talk) 17:28, 4 December 2023 (UTC)
 * I have tested it at Qeshm Island by temporarily changing the main template to sandbox version of it, in this article. Hooman Mallahzadeh (talk) 17:18, 4 December 2023 (UTC)
 * I don't see a "Location in..." autocaption there, and the code is still wrong as I described above. Please continue testing. (Edited to add: I am not sure that autocaption works anywhere. I have copied the live template code to the sandbox, which is the first step before adjusting the sandbox. Please continue testing from that point.) – Jonesey95 (talk) 17:28, 4 December 2023 (UTC)

Incorrect parameter check
Jonesey95 and Hooman Mallahzadeh, in the November 2023 Mapframe implementation, the following check is incorrect: onByDefault= There is no parameter used by this template. Instead, the check should have been for and its alternative. --Paul_012 (talk) 07:27, 22 February 2024 (UTC)
 * map is a valid parameter in this template. It is an alias of pushpin_map. It appears that there are four valid map parameters in this template: image_map or map_image is passed to the infobox's image2 parameter, and pushpin_map or map is passed to the infobox's image3 parameter.
 * Did you write the above message because something is not working as expected? If so, please link to a page where the infobox is not working and explain how it should work instead. – Jonesey95 (talk) 15:45, 22 February 2024 (UTC)
 * Sorry, I was looking at the documentation and forgot to check the template source. My suggestion was prompted by the infobox at New Guinea, which in addition to an already existing image map, now shows a redundant Mapframe map (that is also totally useless due to the wholly inappropriate zoom level, but that's another issue). Given that the default behaviour is not to show Mapframe maps in infoboxes that already have pushpin maps, I think by the same intention, infoboxes that already have image maps should likewise have Mapframe disabled by default. --Paul_012 (talk) 18:39, 22 February 2024 (UTC)
 * Thank you for linking to an example page. It is always helpful. I have added the other two map parameters to the "on by default" test for mapframe maps. I believe that someone could still override the default if desired. – Jonesey95 (talk) 18:45, 22 February 2024 (UTC)
 * Thanks, that was quick! --Paul_012 (talk) 18:47, 22 February 2024 (UTC)
 * Thanks, that was quick! --Paul_012 (talk) 18:47, 22 February 2024 (UTC)