Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.


#58 Disable external links in templates (?)

zim (76)

Hi, I am using kiwix 0.9-alpha5 with wikipedia_it_all_kiwix_03_alpha2.zim

I have noticed that some templates have links in them, for example

contains the following sentence:
"Contribuisci a migliorarla secondo le convenzioni di Wikipedia e i suggerimenti del progetto di riferimento."
with a link on "Contribuisci":$PAGETITLE&action=edit
where $PAGETITLE is the page name (namespace included) in which the Template is shown.

For example with the article

On kiwix this is rendered as http://localhost../articles/a/s/t/Astarpa.html

which open in the browser obviously giving an error.

I think it could be worthwhile considering to pipe out all "external" links in templates, to avoid situation like this.

Same case for:

So, since there are no portals on the ZIM file I think it shuold be either:
* replaced with an external link to online W


  • I do not think this is a good idea, I'm sure they are good external links in template which should not be disable (in fact, disable them is like blank them).

    Another point is that is complicated to do.

    Such situation should be treated IMO case by case.

    What about removing:
    * Template:T

    They do not make sense in a read only view. isn't it?

  • I think that removing S, L, etc. templates is a bad idea. They give important information about the article, i.e. that the article is a stub, it is a incomplete translation or that it has some other kind of problem. So, I think they should not be removed.

    Furthermore, I don't understand why you say they are good external links since they point to the wrong place... and if you manage to make them point to the right place I don't know how much useful that will be since I think that people using the DVD don't have an Internet connection.

    I have seen that other links in templates are disabled (e.g. links to Help pages or Discussion pages)... o I have proposed that ;-).

    What do you mean with treating them case by case?

  • Links to http://localhost*** should be avoided. But If you have a link to on the article of Google, it shouldn't.

    If you remove the external links, what do you want to display instead?

  • In general I think external links should be kept (e.g. in references or bibliography), but these kinds of links no.

    The bad thing is that the "edit" link (as in these examples) are treated as external links because they can not be adapted to follow the "[[...]]" standard link syntax.

    I mean, for example, in the syntax

    [[Roma|capitale d'Italia]] (ValueError('No closing quotation',))
    gives: capitale d'Italia

    But in a Template:S included in page ">
    which is treated as an external link, since you can't use a [[...]]-like syntax but actually points to the edit page. These link are now rendered to http://localhost*. This is the case of the templates that I have indicated below.

    Is there a way to identify this kind of links and disable them, the format is always:

    where XXXX can be "edit" or "history" (the latter if the link points to a previous version of the page).

    I don't know if I have been clear.

  • It's a feature request.

    • labels: --> zim