User:Davidgothberg/Test79

Testing stuff for Template:IP-user other
Link to IPv4 and IPv6 user pages, so I can test there:

User talk:201.83.25.59

User:2001:470:FD:3:0:0:0:80

User:2001:B011:7009:18A0:FC2F:9F5F:5B46:306E

User:2601:192:C180:322F:4C04:641C:A3C3:BDC7

Or even better: Test at Special:ExpandTemplates and set the IP-user pagenames above as "Context title".

((#titleparts:((PAGENAME))|1)))) makes it so for instance "User talk:201.83.25.59/Subpage" becomes:

Testing padleft to check the ":" positions in an IPv6 user pagename:

1: 00000

2: 0000:

3: 0000000000

4: 000000000:

5:

6: ++

25: Below does not work on IPv4 pages since the magic word is sent instead of its value: 25b: But with titleparts the value is sent, so works on IPv4 pages: 25c: 25:

Below does not work on IPv4 pages since the magic word is sent instead of its value:

25b:

But with titleparts the value is sent, so works on IPv4 pages:

25c:

20: ++ 21: ++ 22: ++ 20: ++

21: ++

22: ++

23: ++ 24: ++ 25: ++ 23: ++

24: ++

25: ++

30: ++ 31: ++ 32: ++ 33: ++

30: ++

31: ++

32: ++

33: ++

23: ++ 23: ++ 23: ++

23: ++

23: ++

23: ++

NOTE! Module:IPAddress is white space sensitive. So leave no blanks around the pagename parameter above. Thus, the below code is wrong: 24: ++ 24: ++

See IsIPAddress, Module:IPAddress and doc at Module talk:IPAddress.

MediaWiki:Anontalkpagetext
MediaWiki:Anontalkpagetext is loaded when editing IPv4 users talk pages, but not when editing IPv6 users talk pages. It is loaded above MediaWiki:Talkpagetext. Then the editnotices load.

If I use the namespace editnotice Template:Editnotices/Namespace/User talk to load MediaWiki:Anontalkpagetext for IPv6 users it will end up below MediaWiki:Talkpagetext, thus not looking the same as for IPv4 users. So I have to load it from MediaWiki:Talkpagetext.

My entire code for MediaWiki:Talkpagetext :

Alternative calling Module:IPAddress directly. But is messy:

Oh, I found where MediaWiki:Anontalkpagetext actually is loaded. It is from MediaWiki:Newarticletext. So I should update that one to detect IPv6 pages instead. Where MediaWiki:Newarticletext currently has this code:

}}

Change to this code:

}}

Alternative calling Module:IPAddress directly. But is messy:

}}