https://bugzilla.wikimedia.org/show_bug.cgi?id=22773
Krinkle <krinklem...@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |krinklem...@gmail.com Component|API |Search Blocks| |29097 Summary|OpenSearch: Namespace name |[PrefixSearch] Namespace |part of prefix should not |name part of prefix search |override given namespace |query should not override |id(s) |given namespace id(s) --- Comment #3 from Krinkle <krinklem...@gmail.com> 2011-08-11 10:57:16 UTC --- Renaming and moving bug. Steps to reproduce: * Get a wiki with pages like "Category:Template:Foo" (namespace=14, title="Template:Foo") * Query open search namespace=14&prefix=Template:F * ApiOpenSearch detects "Template:" as a prefix and searches in that namespace, ignoring 14. Source code to confirm: * ApiOpenSearch calls PrefixSearch [1] * PrefixSearch creates a Title object from search query, and calls getNamespace(). If it does not return NS_MAIN, it uses the namespace of that title object, thus overriding and ignoring the given namespace id to search in (line 29 of PrefixSearch.php) See also bug 30323. -- Krinkle [1] http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/includes/api/ApiOpenSearch.php?revision=92400&view=markup#l45 [2] http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/includes/PrefixSearch.php?revision=86255&view=markup#l24 -- Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list Wikibugs-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikibugs-l