Summary: rvexpandtemplates=true does not expand templates in
                    ref tags
           Product: MediaWiki
           Version: 1.17-svn
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: Normal
         Component: API

Any call to the API with action=query, prop=revisions, rvprop=content, and
rvexpandtemplates=true does not have expanded templates in the content when
that template is contained within <ref></ref> tags.

To reproduce, just make any such call to the API.  For example:

Note that the templates within <ref> tags are not expanded:

<ref>{{cite web | title = Train (noun) | work = (definition - Compact OED) |
publisher = Oxford University Press | url = | accessdate =

It should instead expand the template like this:

<ref><span class="citation web"
>[ "Train (noun)"]. ''<nowiki 
>/>(definition - Compact OED)<nowiki />''. Oxford University Press<span 
>class="reference-accessdate">. Retrieved 2008-03-18</span>.</span><span
style="display: none;">&nbsp;</span></span></ref>

This has no good workaround; the best I can find is to grab all of the
unexpanded templates and feed them into another call to the API with
action=expandtemplates and text=(the templates), which is not very good not
only because it's extra hassle, but also because it requires twice as many
calls to the API, which inevitably slows things down considerably.

Build 2010-08-12 on Windows 7 Enterprise (though it being the result of an API
call, I would imagine it reproduces anywhere)

Configure bugmail:
------- You are receiving this mail because: -------
You are on the CC list for the bug.

Wikibugs-l mailing list

Reply via email to