It could be possible to only count real links and not template links by doing this: *List all the links from "What links here" from "Example_article" *Enter to the ones that are in the Template: mainspace *Count the number of links in "What links here" in each template *Then number of real links = total links - links from templates
Maybe someone could code something like that. Also the program should check add all the "what links here" from each template in a list, and delete repeated articles (because one article may have two templates both linking at other article)
On Sun, Feb 6, 2011 at 10:34 PM, Tim Starling tstarling@wikimedia.org wrote:
On 07/02/11 10:56, Carcharoth wrote:
On Sun, Feb 6, 2011 at 10:19 PM, Magnus Manske magnusmanske@googlemail.com wrote:
Many of these links are due to templates, which I can do little about.
Can *anyone*, even in principle, do something about that? It really bugs me that the "what links here" function doesn't distinguish between links arising from templates (often not directly relevant) and links directly from the article wiki-text. If the answer is something to do with parsers, please do explain!
Yes, it's possible. It was necessary to register links from templates in the pagelinks table so that when a page is deleted or created, the HTML caches can be updated so that the link colour will change. With a schema change and some parser work, it would be possible to flag such links so that they are optional in "what links here".
-- Tim Starling
WikiEN-l mailing list WikiEN-l@lists.wikimedia.org To unsubscribe from this mailing list, visit: https://lists.wikimedia.org/mailman/listinfo/wikien-l