Module talk:Check for unknown parameters
Module:Check for unknown parameters is permanently protected from editing because it is a heavily used or highly visible module. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported by consensus, editors may use {{edit protected}} to notify an administrator to make the requested edit.
|
This module was considered for merging on 2019 December 30. The result of the discussion was "no consensus". |
This is the talk page for discussing improvements to the Check for unknown parameters module. |
|
Archives: 1Auto-archiving period: 3 months |
This module does not require a rating on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | ||||||||
|
Error category should also be added in preview
If there is an error category for unknown parameters then it's only added in the rendered page, not previews which instead show a preview warning. That can be very confusing. Consider for example Copa Libertadores Femenina (permanent link) with Category:Pages using flagicon template with unknown parameters. The page has 135 {{flagicon}}. The unknown parameter is in {{flagicon|BRA|side=30px}}
(should have said size). It's common to track down where a category is added by previewing different parts of the code. That fails here when the category is never added in preview. You can search for the preview warning in the preview but users may not know that. Previews can add things but shouldn't remove things. PrimeHunter (talk) 11:36, 9 December 2023 (UTC)
Lua patterns
Is it possible to add a function to use Lua patterns and also limit the number? For example, if the parameter |date=
can be between |date1=
and |date8=
and using regexp1 = "date[%d]+"
and something like reglimit1=8
to limit the allowed parameters? Gonnym (talk) 12:26, 23 June 2024 (UTC)
- Why not write a specific pattern?
regexp1 = "date[1-8]"
- —Trappist the monk (talk) 12:59, 23 June 2024 (UTC)
- Didn't even cross my mind to do that for some reason. I'll try that out, thanks! Gonnym (talk) 13:01, 23 June 2024 (UTC)
- @Trappist the monk doesn't work. Tested it on TNA Impact! by using the /sandbox version in preview. Gonnym (talk) 13:06, 23 June 2024 (UTC)
- Nevermind, got it to work without the quotes of course. I'll update the /doc here. Gonnym (talk) 13:09, 23 June 2024 (UTC)
- You could also look at the check at {{Interlinear}} for a fun example. It supports values of 1–99 for some parameters (actually 1 and higher, but I'm hoping nobody will put in more than 99 unnamed parameters). – Jonesey95 (talk) 19:43, 24 June 2024 (UTC)
- The pattern
[1-9][%d]*
(should probably be written[1-9]%d*
) is not limited to the range 1–99.%d*
means 0 or more digits. So, as long as the first digit is not zero, any number of digits (within reason) will be accepted. If you want to actually limit the range to 1–99 you might use%f[%d][1-9]%d?$
where (right to left)$
anchors the pattern to the end of the parameter name string;%d?
means 0 or 1 digits;[1-9]
requires the first digit of the enumeration to be in the range 1–9;%f[%d]
is the frontier pattern where the next character is a digit but the previous character is not a digit – inabc123
the pattern finds the boundary betweenc
(parameter name) and1
(first digit of the enumerator). - —Trappist the monk (talk) 22:00, 24 June 2024 (UTC)
- The pattern
- You could also look at the check at {{Interlinear}} for a fun example. It supports values of 1–99 for some parameters (actually 1 and higher, but I'm hoping nobody will put in more than 99 unnamed parameters). – Jonesey95 (talk) 19:43, 24 June 2024 (UTC)
- Nevermind, got it to work without the quotes of course. I'll update the /doc here. Gonnym (talk) 13:09, 23 June 2024 (UTC)
Protected eit request on 29 August 2024
--49.15.198.27 (talk) 12:38, 29 August 2024 (UTC)
It is requested that an edit be made to the fully protected module at Module:Check for unknown parameters. (edit · history · last · links · sandbox · edit sandbox · sandbox history · sandbox last edit · sandbox diff · test cases · transclusion count · protection log) This template must be followed by a complete and specific description of the request, so that an editor unfamiliar with the subject matter could complete the requested edit immediately.
Edit requests to fully protected pages should only be used for edits that are either uncontroversial or supported by consensus. If the proposed edit might be controversial, discuss it on the protected page's talk page before using this template. Consider making changes first to the module's sandbox and test them thoroughly here before submitting an edit request. To request that a page be protected or unprotected, make a protection request. When the request has been completed or denied, please add the |
49.15.198.27 (talk) 12:38, 29 August 2024 (UTC)
Amir matta militants
Amir matta 49.15.198.27 (talk) 12:39, 29 August 2024 (UTC)