Wikipedia:User scripts/Requests/Archive 3: Difference between revisions
Content deleted Content added
Line 545:
:That website uses JavaScript which is [http://pcn.loc.gov/Templates/isbncnvt.js open source] so I guess it would be easy to port it here. [[User:SD0001|SD0001]] ([[User talk:SD0001|talk]]) 06:35, 1 January 2019 (UTC)
:{{re|Neveselbert}} At least for English and German books, [[m:User:TMg/autoFormatter]] adds dashes to ISBNs. '''[[User:Sam Sailor|Sam]] [[User talk:Sam Sailor|Sailor]]''' 09:26, 17 April 2019 (UTC)
{{Clear}}
==User script to help guide students working on medical articles==
Students make similar errors when editing and each new batch repeats similar errors made by the last batch. I am wanting a user script that analysis the students edits and provides them feedback. For example:
# If they use a url to the inside net of their library it will remind them that this is not useful to anyone outside their institution.
# If they use caps for every word in a heading it will point out that generally only the first word in a heading gets a cap unless the other words are proper names.
# If they put refs before the punctuation or leave a space after the punctuation before the ref it will remind them that the house style is refs go immediately after the punctuation.
# If they use a book (ie an ISBN) without a page number they will be reminded to provide a page number.
# If they do not use "cite templates" to match those already used in the article they will be requested to do so.
# If they use a pmid that is listed as a "primary source" they will be requested to use a secondary source. Whether or not a pmid is primary or secondary can generally be determined by pubmed.
I am involved with supporting a number of classes, including one of medical students at UCSF. I am wanting to trial this sort of script on them to see if they find it useful and it decreases the work load for other volunteers. Currently education initiatives are not really scalable and this sort of script will help make them so. [[User:Doc James|<span style="color:#0000f1">'''Doc James'''</span>]] ([[User talk:Doc James|talk]] · [[Special:Contributions/Doc James|contribs]] · [[Special:EmailUser/Doc James|email]]) 04:57, 15 March 2018 (UTC)
::First draft [https://en.wikipedia.org/wiki/User:TheSandDoctor/scripts/test2.js here] [[User:Doc James|<span style="color:#0000f1">'''Doc James'''</span>]] ([[User talk:Doc James|talk]] · [[Special:Contributions/Doc James|contribs]] · [[Special:EmailUser/Doc James|email]]) 02:53, 19 March 2018 (UTC)
:::Thanks for [[User:TheSandDoctor|TheSandDoctor]] who already started to work on it. I just want to refer to [[User:ערן/WeaselWords.js]] and [[Wikipedia:Manual of Style/Words to watch/Config]] which can be used as a sketch example how to do it (though someone should review the code which was written in WM'14). Particularally I suggest enwiki to adapt hewiki practices here and to put the "rules" above in two format:
:::* as human readable rules in [[Wikipedia:Manual of Style]] (or a sub page) - where users can read the rational behind the rule. Probably some of the rules [[User:Doc James|<span style="color:#0000f1">'''Doc James'''</span>]] mentioened above are already there - if not please consider to add them. Doing it means users who don't have user script installed can still be aware to it (though it is less accessible)
:::* as machine readable rules (as in [[Wikipedia:Manual of Style/Words to watch/Config]] or some other format) for a user script to verify the rules. Doing it will greatly simplity further adding/removing/twiking the style rules.
:::Thanks, [[User:ערן|Eran]] ([[User talk:ערן|talk]]) 07:30, 21 March 2018 (UTC)
:::You should use [https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/jQuery.plugin.textSelection jquery.textSelection] [https://phabricator.wikimedia.org/source/mediawiki/browse/master/resources/src/jquery/jquery.textSelection.js source] api module to access the contents of the wiki text editors. That synchronises between the various wiki text editors, so that when two tools makes changes to the form value, they don't overwrite each other. —[[User:TheDJ|Th<span style="color: green">e</span>DJ]] ([[User talk:TheDJ|talk]] • [[Special:Contributions/TheDJ|contribs]]) 09:16, 21 March 2018 (UTC)
|