Wikibooks:Reading room/Proposals/2010/May

Counters
This is a small counter extension. Where it is beta code I don't know how appropriate it would be to add it to this site. But I see it as potentially very valuable for doing things like auto-number exercises, examples, etc. Thenub314 (talk) 10:35, 14 May 2010 (UTC)
 * Is there an example of where it can be applied? Kayau ( talk &#124; email &#124; contribs ) 18:39, 14 May 2010 (HKT)


 * Sure, in the Linear Algebra book, for example. More specifically consider Linear Algebra/Gauss' Method. Imagine I want to add a very easy exercise as the first exercise.  Then I need to go through all 22  exercises and increment the number. It is just a bit time consuming, and prone to errors.  Instead I could make an exercise template That has as part of its definition, something to the effect of: " ".  Which, if I understand the documentation correctly, produce "Exercise n" where n is the number exercise we are on.  Then adding a new exercise would be easy as   


 * In my dream world one would be able to store a variable directly and recall it later. This would also allow one to build templates where you could refer to an exercise by some anchor name not visible to the reader and have it appear as "Exercise x" where x is the correct number.  Maybe it is even possible to do this with this extension, but I think it depends on how the template handles the empty string, order things get evaluated in, etc, etc.  It is very difficult to say without out it being around to play with. Does anyone know if the test.wikipedia adds extensions for one to try out?  Probably not.  But maybe I will try to ask if people here think there is any hope of adding this extension. Thenub314 (talk) 11:02, 14 May 2010 (UTC)


 * In that case I support adding this extension. Is there a wiki that uses this extention? I want to try it out at their sandbox. :) Kayau ( talk &#124; email &#124; contribs ) 11:08, 14 May 2010 (UTC)


 * The developers might balk at putting in an extension still listed as being in beta, even if we were to have consensus for it. -- Adrignola talk contribs 12:14, 14 May 2010 (UTC)


 * (To Adrignola) Fair enough. I figured as much. It would still be very nice though. (To Kayau) No wiki uses it that I know of, I just happened upon it. I have asked them to add it at the test wiki, but I think it needs to go through some review process first. Thenub314 (talk) 13:57, 14 May 2010 (UTC)

Variables.
One should never be deterred, so I thought i would try again. Since my request for counters is clearly cannot work, I thought I might see how the community feels about installing mw:Extension:VariablesExtension. This extension is listed as stable and used on a few wiki's. With it I would hope to create automatic numbering and reference templates. The extension simply allows one to store data into a variable, recall data from that variable, and test for existence of the variable. Before I get feedback I have to comment that this extension probably will not be installed. There are strong feelings by the developers that this extension will creep wikitext closer to programming. See 7865 for comments regarding the use of this bug on en.wikipedia. Culturally I don't know if not using it on wikipedia means not using it any wikimedia wiki... I suspect the answer is probably yes. But at the end of the day we are a different project with different needs. If we aspire to having dozens of mathematics texts following the usual style of numbering and referencing hundreds of problems, theorems, lemmas etc, in each book it seems advisable to find an easier way to handling numbering and references. (This is probably true for many subjects, but I will leave it to those that know better to decide their needs.)  I do appreciate why you don't want to be able to program within a mediawiki page, so I partially understand their position. But it is the best option available to us at the moment. Thenub314 (talk) 19:59, 14 May 2010 (UTC)
 * Just because Wikipedia doesn't use something doesn't mean Wikibooks can't. Wikiepdia is much more famous, has much more active users and edit counts than Wikibooks — that's what makes Wikipedia different than its other sister projects. If Wikipedia has flagged revs, for example, it would be dead tough for users to edit and be visible and updates are so common in Wikipedia. But in Wikibooks there are enough RC patrollers to sight edits, and every single bit of vandalism can be removed. And there is always the old reviewed pages thing. So that's what make the two projects different, and not implementing an extension on one wiki does not guarantee that it will not be utilised on another. As for the variables extension, I'll try to see what it does before I comment... Kayau ( talk &#124; email &#124; contribs ) 01:10, 15 May 2010 (UTC)
 * I agree we are a different project, and so in principle rejection for wikipedia shouldn't mean much for us (unless of course it was for performance issues). The reason I feel there might be a bit of hesitation is because of 13894, which was closed immediately as a duplicate despite being on another project.  Also, comment #5 at 8570 I think gets to the heart of the objections against it.  To quote: "... Tim's point was not one of performance [...] but of furthering this nasty trend of taking wiki markup somewhere it should not be going. ..."  A rather frustrating point is that some rather nice automatic numbering is part of html/css, but as far as I can see there is no way to take advantage of that since everything needs to be defined in the pages header.  Thenub314 (talk) 08:29, 15 May 2010 (UTC)
 * The rationale given on that bug applies to all WMF wikis. That said, there was some recent discussion about enabling some limited "sandboxed" programmatic functions, perhaps using python or (server-side-)javascript, or a new invented pseudolanguage (possibly based on what's used in AbuseFilter. AFAIK, there's been no agreement among developers on how best to go about doing this, nor any progress in implementation. I'll try to find the thread to link here for folks to read. &mdash; mikelifeguard@enwikibooks:&#126;$ 14:23, 15 May 2010 (UTC)