Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support non-template-namespace templates #142

Open
tacsipacsi opened this issue Oct 7, 2023 · 0 comments
Open

Support non-template-namespace templates #142

tacsipacsi opened this issue Oct 7, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@tacsipacsi
Copy link

In wikitext, page titles after {{ default to the template namespace, but can be overridden by explicitly specifying a namespace, or : to transclude a mainspace page. PetScan implements the first part – defaulting to the template namespace –, but not the second, the ability to override the namespace. Consequently, pages transcluded from other namespaces cannot be searched for using the textareas at Templates&links / Templates.

If I understand the code correctly, this is what happens when I input something in the Has all of these templates: field:

Input Actual SQL fragment Expected SQL fragment Correct?
Title lt_namespace=10 AND lt_title='Title' lt_namespace=10 AND lt_title='Title' Yes
Module:Title lt_namespace=10 AND lt_title='Module:Title' lt_namespace=828 AND lt_title='Title' No
:Title lt_namespace=10 AND lt_title=':Title' lt_namespace=0 AND lt_title='Title' No

The latter two should be fixed.

Reference: https://en.wikipedia.org/w/index.php?title=User_talk:Magnus_Manske&diff=1178068305

@magnusmanske magnusmanske added the enhancement New feature or request label Jan 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants