In my MW 2.28.2 site, I placed the following code into a page:
{{#invoke:String|len|This is a Test}}
It did not execute as expected, it only appeared as text.
From the documentation page on the string module [0], it is not clear to me how to enable this capability.
How do I enable the String Module in my site?
[0] https://www.mediawiki.org/wiki/Module:String
-Rich
Hi, MediaWiki version 2.28.2 doesn’t exist.... I assume you mean 1.28.2? — Amanda
On Thursday, January 4, 2018, 10:18 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
In my MW 2.28.2 site, I placed the following code into a page:
{{#invoke:String|len|This is a Test}}
It did not execute as expected, it only appeared as text.
From the documentation page on the string module [0], it is not clear to me how to enable this capability.
How do I enable the String Module in my site?
[0] https://www.mediawiki.org/wiki/Module:String
-Rich
_______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
I’m not very experienced with modules. However, what I’ve found is that when you invoke a module like you described, and then it doesn’t do what it is supposed to do, it sometimes means that the module is dependent on another sub module that is missing. Does the page where the module has been invoked display something like “LUA ERROR: Module XYZ NOT FOUND” where the output of the invoked module is supposed to be? If yes, you need to add whatever XYZ is in order for the first module to work. If not, I unfortunately cannot guide you further. I always import all my modules from Wikimedia using the Scribunto extension, so this is not one of my areas of high expertise. — Amanda
On Thursday, January 4, 2018, 10:26 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
*derp* .. yes. Thank you.
That said.. any insight where to start with "modules"?
Thank you! -Rich
I assume you mean 1.28.2? — Amanda
_______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Gotcha. Thanks.
No. no errors or any messages of any kind. It just appears as text as if I placed it inside of a <nowiki> tagset.
I had never even heard of "modules" before now.
-Rich
-----Original Message----- From: MediaWiki-l [mailto:mediawiki-l-bounces@lists.wikimedia.org] On Behalf Of Amanda Quad Sent: Thursday, January 04, 2018 10:30 AM To: MediaWiki announcements and site admin list Subject: Re: [MediaWiki-l] How to calculate the length of a string
I’m not very experienced with modules. However, what I’ve found is that when you invoke a module like you described, and then it doesn’t do what it is supposed to do, it sometimes means that the module is dependent on another sub module that is missing. Does the page where the module has been invoked display something like “LUA ERROR: Module XYZ NOT FOUND” where the output of the invoked module is supposed to be? If yes, you need to add whatever XYZ is in order for the first module to work. If not, I unfortunately cannot guide you further. I always import all my modules from Wikimedia using the Scribunto extension, so this is not one of my areas of high expertise. — Amanda
On Thursday, January 4, 2018, 10:26 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
*derp* .. yes. Thank you.
That said.. any insight where to start with "modules"?
Thank you! -Rich
I assume you mean 1.28.2? — Amanda
_______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
_______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Yep, that confirms it. If the invoked module just appears as plain text as if within nowiki tags, it means that the Scribunto extension is either not installed or not configured properly. That extension is required for most modules to work. https://mediawiki.org/wiki/Extension:Scribunto — Amanda
On Thursday, January 4, 2018, 10:33 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
Gotcha. Thanks.
No. no errors or any messages of any kind. It just appears as text as if I placed it inside of a <nowiki> tagset.
I had never even heard of "modules" before now.
-Rich
-----Original Message----- From: MediaWiki-l [mailto:mediawiki-l-bounces@lists.wikimedia.org] On Behalf Of Amanda Quad Sent: Thursday, January 04, 2018 10:30 AM To: MediaWiki announcements and site admin list Subject: Re: [MediaWiki-l] How to calculate the length of a string
I’m not very experienced with modules. However, what I’ve found is that when you invoke a module like you described, and then it doesn’t do what it is supposed to do, it sometimes means that the module is dependent on another sub module that is missing. Does the page where the module has been invoked display something like “LUA ERROR: Module XYZ NOT FOUND” where the output of the invoked module is supposed to be? If yes, you need to add whatever XYZ is in order for the first module to work. If not, I unfortunately cannot guide you further. I always import all my modules from Wikimedia using the Scribunto extension, so this is not one of my areas of high expertise. — Amanda
On Thursday, January 4, 2018, 10:26 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
*derp* .. yes. Thank you.
That said.. any insight where to start with "modules"?
Thank you! -Rich
I assume you mean 1.28.2? — Amanda
_______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
_______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l _______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Ok.. I have the Extention:Scibunto installed, now my page code responds with:
--- Script error: No such module "String". ---
Does this mean I need to now manually install the "String" Module? (just hoping for confirmation that I'm on the right path..)
-Rich
Yes, you are on the right path. You need to manually install the “String” module and any other sub modules that it depends on. — Amanda
On Thursday, January 4, 2018, 11:27 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
Ok.. I have the Extention:Scibunto installed, now my page code responds with:
--- Script error: No such module "String". ---
Does this mean I need to now manually install the "String" Module? (just hoping for confirmation that I'm on the right path..)
-Rich _______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
I see that the Scibunto extension created a namespace called "Module". Are Modules like Widets? Do I just create a page called "Module:String" and copy/paste the code into it from https://en.wikipedia.org/wiki/Module:String ?
-Rich
Read the pages dealing with Lua. The extension installs a new namespace called Module, it’s like the the template namespace. When using invoke you’re calling a module, like you would with a template. So you need to copy over modules from Mediawiki, Wikipedia, etc., or create your own, modules.
Sent from my iPad
On Jan 4, 2018, at 8:26 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
Ok.. I have the Extention:Scibunto installed, now my page code responds with:
--- Script error: No such module "String". ---
Does this mean I need to now manually install the "String" Module? (just hoping for confirmation that I'm on the right path..)
-Rich _______________________________________________ MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
If I visit: https://www.mediawiki.org/w/index.php?title=Module:String&action=raw
And copy/paste the raw content to a page called Module:String on my wiki.. do I need to change the content model of the Module page?
I did just that and the page Module:String on my wiki does not look at all like code.. it look like an article..
Also.. when I refresh the page that calls the module.. I still get the same error as before I created the Module:String page, namely:
--- Script error: No such module "String". ---
-Rich
You have to install extension: Scribunto. It allows you to use lua. Check the document links from the extension page, or google lua Mediawiki and you should everything you need.
Sent from my iPad
On Jan 4, 2018, at 7:26 AM, Evans, Richard K. (GRC-H000) richard.k.evans@nasa.gov wrote:
*derp* .. yes. Thank you.
That said.. any insight where to start with "modules"?
Thank you! -Rich
I assume you mean 1.28.2? — Amanda
MediaWiki-l mailing list To unsubscribe, go to: https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
mediawiki-l@lists.wikimedia.org