MediaWiki API 幫助

這是自動生成的MediaWiki API文檔頁面。

文檔和例子:https://www.mediawiki.org/wiki/API:Main_page/zh

list=prefixsearch (ps)

main | query | prefixsearch
  • 此模塊需要讀取權限。
  • 此模塊可作為發生器使用。
  • 來源:MediaWiki
  • 許可協議:GPL-2.0+

為頁面標題執行前綴搜索。

Despite the similarity in names, this module is not intended to be equivalent to Special:PrefixIndex; for that, see action=query&list=allpages with the apprefix parameter. The purpose of this module is similar to action=opensearch: to take user input and provide the best-matching titles. Depending on the search engine backend, this might include typo correction, redirect avoidance, or other heuristics.

參數:
pssearch

搜索字符串。

這個參數是必須的。
psnamespace

搜索的名字空間。

值(以|分隔):0、1、2、3、4、5、6、7、8、9、10、11、12、13、14、15、2300、2301、2302、2303
默認:0
pslimit

要返回的結果最大數。

不允許超過100個(對于機器人則是200個)。
類型:整數或max
默認:10
psoffset

跳過的結果數。

類型:整數
默認:0
例子:
搜索以meaning開頭的頁面標題。
api.php?action=query&list=prefixsearch&pssearch=meaning [在沙盒中打開]