58:
30:
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with "importScript", "mw.loader.load", "iusc", or "lusc", take note that this causes you to dynamically load a remote script, which could be changed by
31:
others. Editors are responsible for all edits and actions they perform, including by scripts. User scripts are not centrally supported and may malfunction or become inoperable due to software changes.
36:
68:
35:
to help you find broken scripts is available. If you are unsure whether code you are adding to this page is safe, you can ask at the
732:// Categories should be on new lines, so split by new line, sort alphabetically with a few checks, then join again with new lines.
105:
32:
1325:// Merge pre-category text back with the sorted and joined category text, place back in textbok and add summary.
64:
739:// Checks: eponymous categories are listed first; categories are sorted without preceding "The"
610:// Get the text up to the start of the categories, and then all of the text with the categories.
17:
57:
80:
After saving, you have to bypass your browser's cache to see the changes.
104:
toolbar button. For details and instructions about other browsers, see
52:
26:
1396:"Sorted categories alphabetically via ]."
397:"Go to the edit page to use this script."
286:// Determine if we need to go to the editing page.
8:
97:
67:seems to have a documentation page at
45:be executed when previewing this page.
7:
112:
69:User:Alex 21/script-categoriessort
24:
106:Knowledge (XXG):Bypass your cache
56:
1:
1478:
1458:
1451:
1444:
1437:
1403:
1369:
1329:
1322:
1318:
1290:
1283:
1258:
1254:
1175:
1096:
1092:
1013:
934:
930:
872:
811:
774:
743:
736:
729:
725:
688:
645:
614:
607:
603:
560:
535:
510:
491:
484:
480:
455:
424:
417:
404:
223:'Sort categories'
388:
321:
290:
283:
267:
230:
181:
141:
116:
113:
37:appropriate village pump
503:"[[Category:"
369:'action=submit'
487:// Categories to check
1418:'wpMinoredit'
342:'action=edit'
1344:textBeforeCategories
651:textBeforeCategories
448:'wpTextbox1'
420:// Get textbox value
1384:'wpSummary'
596:"wgTitle"
1356:textWithCategories
1293:textWithCategories
755:textWithCategories
694:textWithCategories
100:key and click the
914:categoryEponymous
899:categoryEponymous
853:categoryEponymous
838:categoryEponymous
566:categoryEponymous
75:
74:
49:
48:
1469:
1463:
1462:
1456:
1455:
1449:
1448:
1442:
1441:
1435:
1434:
1431:
1428:
1425:
1422:
1419:
1416:
1413:
1410:
1407:
1401:
1400:
1397:
1394:
1391:
1388:
1385:
1382:
1379:
1376:
1373:
1367:
1366:
1363:
1360:
1357:
1354:
1351:
1348:
1345:
1342:
1339:
1336:
1333:
1327:
1326:
1320:
1316:
1315:
1312:
1309:
1306:
1303:
1300:
1297:
1294:
1288:
1287:
1281:
1280:
1277:
1274:
1271:
1268:
1265:
1262:
1256:
1252:
1251:
1248:
1245:
1242:
1239:
1236:
1233:
1230:
1227:
1224:
1221:
1218:
1215:
1212:
1209:
1206:
1203:
1200:
1197:
1194:
1191:
1188:
1185:
1182:
1179:
1173:
1172:
1169:
1166:
1163:
1160:
1157:
1154:
1151:
1148:
1145:
1142:
1139:
1136:
1133:
1130:
1127:
1124:
1121:
1118:
1115:
1112:
1109:
1106:
1103:
1100:
1094:
1090:
1089:
1086:
1083:
1080:
1077:
1074:
1071:
1068:
1065:
1062:
1059:
1056:
1053:
1050:
1047:
1044:
1041:
1038:
1035:
1032:
1029:
1026:
1023:
1020:
1017:
1011:
1010:
1007:
1004:
1001:
998:
995:
992:
989:
986:
983:
980:
977:
974:
971:
968:
965:
962:
959:
956:
953:
950:
947:
944:
941:
938:
932:
928:
927:
924:
921:
918:
915:
912:
909:
906:
903:
900:
897:
894:
891:
888:
885:
882:
879:
876:
870:
869:
866:
863:
860:
857:
854:
851:
848:
845:
842:
839:
836:
833:
830:
827:
824:
821:
818:
815:
809:
808:
805:
802:
799:
796:
793:
790:
787:
784:
781:
778:
772:
771:
768:
765:
762:
759:
756:
753:
750:
747:
741:
740:
734:
733:
727:
723:
722:
719:
716:
713:
710:
707:
704:
701:
698:
695:
692:
686:
685:
682:
679:
676:
673:
670:
667:
664:
661:
658:
655:
652:
649:
643:
642:
639:
636:
633:
630:
627:
624:
621:
618:
612:
611:
605:
601:
600:
597:
594:
591:
588:
585:
582:
579:
576:
573:
570:
567:
564:
558:
557:
554:
553:"The "
551:
548:
545:
542:
539:
533:
532:
529:
526:
523:
520:
517:
514:
508:
507:
504:
501:
498:
495:
489:
488:
482:
478:
477:
474:
471:
468:
465:
462:
459:
453:
452:
449:
446:
443:
440:
437:
434:
431:
428:
422:
421:
415:
414:
411:
408:
402:
401:
398:
395:
392:
386:
385:
382:
379:
376:
373:
370:
367:
364:
361:
358:
355:
352:
349:
346:
343:
340:
337:
334:
331:
328:
325:
319:
318:
315:
312:
309:
306:
303:
300:
297:
294:
288:
287:
281:
280:
277:
274:
271:
265:
264:
261:
258:
255:
252:
249:
246:
243:
240:
237:
234:
228:
227:
224:
221:
218:
215:
212:
209:
206:
203:
200:
197:
194:
191:
188:
185:
179:
178:
175:
172:
169:
166:
163:
160:
157:
154:
151:
148:
145:
139:
138:
135:
132:
129:
126:
123:
120:
109:
96:: Hold down the
60:
53:
27:
1477:
1476:
1472:
1471:
1470:
1468:
1467:
1466:
1465:
1464:
1460:
1457:
1453:
1450:
1446:
1443:
1439:
1436:
1432:
1429:
1426:
1423:
1420:
1417:
1414:
1411:
1408:
1405:
1402:
1398:
1395:
1392:
1389:
1386:
1383:
1380:
1377:
1374:
1371:
1368:
1364:
1361:
1358:
1355:
1352:
1349:
1346:
1343:
1340:
1337:
1334:
1331:
1328:
1324:
1321:
1317:
1313:
1310:
1307:
1304:
1301:
1299:splitCategories
1298:
1295:
1292:
1289:
1285:
1282:
1278:
1275:
1272:
1269:
1266:
1263:
1260:
1257:
1253:
1249:
1246:
1243:
1240:
1237:
1234:
1231:
1228:
1225:
1222:
1219:
1216:
1213:
1210:
1207:
1204:
1201:
1198:
1195:
1192:
1189:
1186:
1183:
1180:
1177:
1174:
1170:
1167:
1164:
1161:
1158:
1155:
1152:
1149:
1146:
1143:
1140:
1137:
1134:
1131:
1128:
1125:
1122:
1119:
1116:
1113:
1110:
1107:
1104:
1101:
1098:
1095:
1091:
1087:
1084:
1081:
1078:
1075:
1072:
1069:
1066:
1063:
1060:
1057:
1054:
1051:
1048:
1045:
1042:
1039:
1036:
1033:
1030:
1027:
1024:
1021:
1018:
1015:
1012:
1008:
1005:
1002:
999:
996:
993:
990:
987:
984:
981:
978:
975:
972:
969:
966:
963:
960:
957:
954:
951:
948:
945:
942:
939:
936:
933:
929:
925:
922:
919:
916:
913:
910:
907:
904:
901:
898:
895:
892:
889:
886:
883:
880:
877:
874:
871:
867:
864:
861:
858:
855:
852:
849:
846:
843:
840:
837:
834:
831:
828:
825:
822:
819:
816:
813:
810:
806:
803:
800:
797:
794:
791:
788:
785:
782:
779:
777:splitCategories
776:
773:
769:
766:
763:
760:
757:
754:
751:
749:splitCategories
748:
745:
742:
738:
735:
731:
728:
724:
720:
717:
714:
712:categoriesStart
711:
708:
705:
702:
699:
696:
693:
690:
687:
683:
680:
677:
675:categoriesStart
674:
671:
668:
665:
662:
659:
656:
653:
650:
647:
644:
640:
637:
634:
631:
628:
625:
622:
620:categoriesStart
619:
616:
613:
609:
606:
602:
598:
595:
592:
589:
586:
583:
580:
577:
574:
571:
568:
565:
562:
559:
555:
552:
549:
546:
543:
540:
537:
534:
530:
527:
524:
521:
518:
515:
512:
509:
505:
502:
499:
496:
493:
490:
486:
483:
479:
475:
472:
469:
466:
463:
460:
457:
454:
450:
447:
444:
441:
438:
435:
432:
429:
426:
423:
419:
416:
412:
409:
406:
403:
399:
396:
393:
390:
387:
383:
380:
377:
374:
371:
368:
365:
362:
359:
356:
353:
350:
347:
344:
341:
338:
335:
332:
329:
326:
323:
320:
316:
313:
310:
307:
304:
301:
298:
295:
292:
289:
285:
282:
278:
275:
272:
269:
266:
262:
259:
256:
253:
250:
247:
244:
241:
238:
235:
232:
229:
225:
222:
219:
216:
213:
210:
207:
204:
201:
198:
195:
192:
189:
186:
183:
180:
176:
173:
170:
167:
164:
161:
158:
155:
152:
149:
146:
143:
140:
136:
133:
130:
127:
124:
121:
118:
115:
111:
110:
99:
76:
50:
40:
22:
21:
20:
12:
11:
5:
1475:
1473:
1412:getElementById
1378:getElementById
1362:"\n"
1350:"\n"
1311:"\n"
767:"\n"
528:"A "
442:getElementById
276:preventDefault
211:'p-tb'
205:addPortletLink
114:
90:Microsoft Edge
73:
72:
61:
51:
47:
46:
25:
23:
15:
14:
13:
10:
9:
6:
4:
3:
2:
1474:
1459:
1452:
1445:
1438:
1404:
1370:
1330:
1323:
1319:
1291:
1284:
1270:localeCompare
1259:
1255:
1176:
1097:
1093:
1014:
935:
931:
873:
812:
775:
744:
737:
730:
726:
689:
646:
615:
608:
604:
561:
536:
511:
492:
485:
481:
456:
425:
418:
405:
389:
322:
291:
284:
268:
231:
182:
142:
117:
107:
103:
95:
91:
87:
83:
82:Google Chrome
79:
70:
66:
62:
59:
55:
54:
44:
38:
34:
29:
28:
19:
700:wpTextbox1_V
657:wpTextbox1_V
626:wpTextbox1_V
461:wpTextbox1_V
101:
93:
89:
85:
81:
77:
42:
18:User:Alex 21
1079:categoryThe
1055:categoryThe
1040:categoryThe
1000:categoryThe
976:categoryThe
961:categoryThe
541:categoryThe
239:portletlink
217:'#'
187:portletlink
65:user script
1332:wpTextbox1
467:wpTextbox1
430:wpTextbox1
354:&&
41:This code
1241:categoryA
1217:categoryA
1202:categoryA
1162:categoryA
1138:categoryA
1123:categoryA
516:categoryA
1406:document
1372:document
1247:category
1168:category
1085:category
1006:category
789:function
638:category
572:category
547:category
522:category
497:category
436:document
308:location
251:function
171:function
125:function
1424:checked
1235:replace
1156:replace
1073:replace
994:replace
632:indexOf
363:indexOf
336:indexOf
98:⇧ Shift
86:Firefox
33:A guide
1261:return
1208:length
1190:substr
1129:length
1111:substr
1046:length
1028:substr
967:length
949:substr
920:return
905:length
887:substr
859:return
844:length
826:substr
706:substr
663:substr
584:config
302:window
150:loader
102:Reload
94:Safari
1390:value
1338:value
761:split
473:value
391:alert
245:click
156:using
78:Note:
63:This
16:<
1430:true
1305:join
783:sort
718:trim
681:trim
410:else
375:<
348:<
314:href
199:util
165:then
92:and
43:will
1461:});
1454:});
1447:});
1286:});
923:1e8
865:1e8
746:var
721:();
691:var
684:();
648:var
617:var
590:get
563:var
538:var
513:var
494:var
458:var
427:var
357:loc
330:loc
296:loc
293:var
279:();
184:var
1421:).
1393:+=
1387:).
1314:);
1279:);
1250:);
1214:==
1178:if
1171:);
1135:==
1099:if
1088:);
1052:==
1016:if
1009:);
973:==
937:if
911:==
875:if
850:==
814:if
770:);
715:).
678:).
641:);
599:);
578:mw
451:);
400:);
324:if
242:).
233:$
226:);
193:mw
174:()
162:).
144:mw
131:$
119:$
88:,
84:,
1440:}
1433:;
1427:=
1415:(
1409:.
1399:;
1381:(
1375:.
1365:;
1359:+
1353:+
1347:+
1341:=
1335:.
1308:(
1302:.
1296:=
1276:b
1273:(
1267:.
1264:a
1244:,
1238:(
1232:.
1229:b
1226:=
1223:b
1220:)
1211:)
1205:.
1199:,
1196:0
1193:(
1187:.
1184:b
1181:(
1165:,
1159:(
1153:.
1150:a
1147:=
1144:a
1141:)
1132:)
1126:.
1120:,
1117:0
1114:(
1108:.
1105:a
1102:(
1082:,
1076:(
1070:.
1067:b
1064:=
1061:b
1058:)
1049:)
1043:.
1037:,
1034:0
1031:(
1025:.
1022:b
1019:(
1003:,
997:(
991:.
988:a
985:=
982:a
979:)
970:)
964:.
958:,
955:0
952:(
946:.
943:a
940:(
926:;
917:)
908:)
902:.
896:,
893:0
890:(
884:.
881:b
878:(
868:;
862:-
856:)
847:)
841:.
835:,
832:0
829:(
823:.
820:a
817:(
807:{
804:)
801:b
798:,
795:a
792:(
786:(
780:.
764:(
758:.
752:=
709:(
703:.
697:=
672:,
669:0
666:(
660:.
654:=
635:(
629:.
623:=
593:(
587:.
581:.
575:+
569:=
556:;
550:+
544:=
531:;
525:+
519:=
506:;
500:=
476:;
470:.
464:=
445:(
439:.
433:=
413:{
407:}
394:(
384:{
381:)
378:0
372:)
366:(
360:.
351:0
345:)
339:(
333:.
327:(
317:;
311:.
305:.
299:=
273:.
270:e
263:{
260:)
257:e
254:(
248:(
236:(
220:,
214:,
208:(
202:.
196:.
190:=
177:{
168:(
159:(
153:.
147:.
137:{
134:)
128:(
122:(
108:.
71:.
39:.
Text is available under the Creative Commons Attribution-ShareAlike License. Additional terms may apply.