On Mon, Aug 16, 2010 at 1:02 PM, Alex Brollo <alex.bro...@gmail.com> wrote:
> Thanks!
>
> I just tried to build a template like this:
>
> [[File:Library-logo-blue-outline.png|30px|link=http://toolserver.org/~magnus/book2scroll/index.html
> ?lang=it&file={{urlencode:{{PAGENAME}}}}]], to be used into Index: pages.
>
> But urlencode converts spaces into +, where your script doesn't like the
> output of urlencode... it only likes names where spaces are replaced by
> underscores.
>
> How can I obtain this transformation by a parser function/by a template? Or:
> can you modify the scripts, so that url encoded titles are accepted too?
>
> I apologyze, if my question is banal.

Not at all, though
http://toolserver.org/~magnus/book2scroll/index.html?lang=it&file=De%27+matematici+italiani+anteriori+all%27invenzione+della+stampa.djvu
seems to work fine. You can also try {{PAGENAMEE}} (note the two E).

Note that sometimes, the Index: name is not the same at the actual
.djvu file, so you should allow attribute {{{1}}} to be the filename
(PAGENAME by default), and maybe the start page as {{{2}}}, default
"1". That would also allow for the template to be used anywhere, not
just on the index page.

Cheers,
Magnus

_______________________________________________
Wikisource-l mailing list
Wikisource-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikisource-l

Reply via email to