[00:01:06] Is it declared global? [00:01:21] yes [00:01:46] Otherwise, i guess if its running very early in initialization before $wgContLang is initialized [00:01:50] but that happens very early [00:04:17] That appeared to be an issue Oct 2017. But I'm trying a version which was released more recently. [11:00:05] I would like to donate but rather use swish or anything else but a credit card [13:46:12] I need to export-import all the citation templates. What is the best way to do this? [14:16:55] hi [14:18:34] jubo2: What do you mean? Special:Export on a Wikipedia wiki, tick "include templates", then import via special:import on your wiki? [14:19:09] Reedy: yeah. I know that. But which template to pull so that all the other citation templates come along? [14:19:25] I'd like all the citation templates [14:19:31] Are they categorised? [14:19:50] I dunno. If they are I can just select to pull all from the category [15:51:53] trying to update an old extension for 1.32 getting an error with $wgContLang->specialPage( '...' ); looking in the manual it should still work [16:06:06] Whats the error? [16:08:48] Call to undefined method LanguageEn::specialPage() [16:15:00] Ah. Well it probably doesnt work anymore [16:15:28] Try using SpecialPageFactory::getTitleFor or something [16:15:43] Cant remember the exact name of the func [16:35:43] SpecialPageFactory::getTitleForAlias() seems to do it, still other errors though so can't tell for sure if it works [16:58:45] errors are all gone, thanks bawolff [16:59:14] :) [19:11:06] Hello and BIG thanks for the most awesome wiki engine [19:14:50] I'm trying to import citation templates. I exported all the templates in [[w:Category:Citation Style 1 templates]] to a file and when I tried to load it to my new wiki I got an error that the import failed because "sanitized-css" was not installed. So I looked it up and installed extension TemplateStyles. Trying to redo the import I get MW error. When I'm looking at a page where {{cite_web}} is being used, in the it reads {{#invoke: [19:14:52] citation/CS1|citation |CitationClass=book }} [19:15:26] How do I fix this? I did enable the TemplateStyles. I don't know what that {{#invoke:citation/CS1|citation |CitationClass=book }} means [19:17:33] Thats part of extensikn:Scribunto [19:17:49] !wptemplates [19:17:49] To copy templates from Wikipedia, use Special:Export and check the "Include templates" option to get all the sub-templates, then upload the file with Special:Import on your wiki. You'll also likely have to install the ParserFunctions extension, Scribunto extension and install/enable HTML tidy. You also might need some CSS from Wikipedia's Common.css. You'll also need a lot of... [19:17:57] bawolff: ah. ok. thanks. So installing Scribunto would fix the situation [19:18:05] Hopefully [19:18:27] Or you know, get to the next error :P [19:22:33] bawolff: you were right. After installing Scribunto I get error where the tag is: "Script error: No such module "citation/CS1"." [19:23:23] Yeah. Invoke is like templates but in the module namespace [19:23:26] So I guess I need to export-import some modules. Not very comfortable in doing that as I don't know what a "modeule" is [19:23:54] Basically just templates but in a different language [19:23:54] bawolff: suggestions, please? [19:24:06] Oh, ok. [19:24:41] They should be included when you do a recursive export i think (just like templates) [19:25:06] bawolff: Ok.. export which category or which module? [19:26:00] Module:citation/CS1 [19:26:17] But you also need every module that module includes [19:27:09] bawolff: how do I get those? [19:27:44] Same as templates. Use special:export [19:29:15] but the field to the left of "Add" expects a category, not something else (in Special:Export) [19:31:06] I exported Module:citation/CS1 and I gonna try importing it now [19:33:06] Trying to import I get '[8b833999c2ed3a066d2b0069] 2019-04-03 19:32:42: Fatal exception of type "Error"' [19:34:32] Maybe I messed up doing the original import of [[w:Category:Citation Style 1 templates]] because I chose "Import to namespace -> Template" instead of choosing "default namespace" [19:36:37] The import of [[w:Category:Citation Style 1 templates]], choosing "Import to namespace Template" that ended in error about a missing content handler for css-sanitized imported these: https://wiki.ban-covert-modeling.org/wiki/Special:RecentChanges?hidebots=1&translations=filter&limit=500&days=14&urlversion=2 [19:38:03] bawolff: Would importing of http://en.wikipedia.org/wiki/Special:Search?go=Go&search=w:Module:citation/CS1 and associated templates require some Extension or something for the modules to be installed. That error message I got really doesn't say anything [19:41:34] The list of pages to export when putting [[w:Category:Citation Style 1 templates]] into the field left of "Add" (in the Special:Export) and hitting "Add" produces this list: http://dpaste.com/04X8DR6 so I did an error by choosing in the import dialogue "Import to Templates-namespace" instead of "Import to default places" [19:42:13] Maybe I should delete the imported Templates and try again.. [19:54:06] I need to figure out a way to get the modules that are needed by the citation templates. But now I delete the wrongly imported templates (and the few other things in the import which falsely went into the Template:-namespace) [19:54:32] and then I start the backupping process and eat something while it runs [20:23:29] I want to bring focus on this talk before it goes unnoticed, in case someone knows the answer: https://www.mediawiki.org/wiki/API_talk:Main_page#Need_clarity_on_where_to_post [20:23:37] > Is there no general place where I can send people? In this case, the question is about someone wanting to report intent to make lots of calls, and wondering about the etiquette of that. [20:25:42] https://www.mediawiki.org/wiki/API:Etiquette [20:34:35] If nothing else id say api mailing list [20:52:51] So... I would like to make the most common citation templates to work on a new wiki. I did export all the pages in [[w:Category:Citation Style 1 templates]] and I've installed Scribunto and TemplateStyles. Then I exported http://en.wikipedia.org/wiki/Special:Search?go=Go&search=w:Module:Citation/CS1. Is there anything else before I'm ready to import http://en.wikipedia.org/wiki/Special:Search?go=Go&search=w:Module:Citation/CS1 and after that the [20:52:52] pages from [[w:Category:Citation Style 1 templates]] ? [21:09:04] jubo2: ParserFunctions, in the past Tidy the config but went through a lot of changes so maybe not necessary anymore [21:10:04] tgr: ParserFunctions I activated when I ran the Mediawiki installer [21:10:08] also set request timeout to an hour or something, if you are doing this on some average shared host / virtual server [21:10:58] tgr: huh.. for me? [21:11:24] I got 2 vCPU, 4GB RAM and 40GB NVMe disk so no performance problems [21:40:32] tgr: What's tidy? [21:40:50] !tidy [21:40:50] HTML Tidy is an external application that cleans up HTML for XHTML compliance (such as bad user input like
). Prior to the new preprocessor in 1.12 it was also needed for distributed, transcluded, or conditional HTML, or mixed HTML and wikitables, but newer versions allow it without Tidy. See [21:46:26] which is a bit outdated, as recent versions of MediaWiki don't actually use Tidy [21:46:35] ok [21:47:00] I have made backups of /var/www and mysqldumps and checked that they load [21:47:04] but the name stuck, so it's the name for the config setting for what tool is used to fix invalid HTML in article / template content [21:47:46] historically, content imported from Wikipedia looked very broken with default tidy settings, not sure if that's still the case [21:47:49] But one would not expect the citation templates to contain bad HTML [21:58:01] I'm looking at https://www.mediawiki.org/wiki/Manual:Using_content_from_Wikipedia [22:02:45] I make no assumptions about wikipedia content. You would be surprised [22:06:06] muhahaha...