Mediawiki API错误:参数'prop'的无法识别的值:提取 [英] Mediawiki API error: Unrecognized value for parameter 'prop': extracts

查看:94
本文介绍了Mediawiki API错误:参数'prop'的无法识别的值:提取的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个新安装的mediawiki.我正在尝试使用API​​来简单地获取一篇文章.我正在使用的API网址是:

I have a new installation of mediawiki. I am trying to use the API to simply get an article. The API url I am using is:

https://example. com/mediawiki/api.php?action = query& format = json& prop = extracts& titles = Vendor_cisco

转到该网址后,我得到:参数'prop'的无法识别的值:提取物

Upon going to that URL I get: Unrecognized value for parameter 'prop': extracts

这似乎很奇怪,因为以下所有URL都能正常工作并返回正确的数据:

This seems odd because all of the following urls do work and return the right data:

https://example. com/mediawiki/api.php?action = query& format = json& prop = links& titles = Vendor_cisco https://example.com/mediawiki /api.php?action=query&format=json&prop=categories&titles=Vendor_cisco https://example.com/mediawiki /api.php?action=query&format=json&prop=revisions&titles=Vendor_cisco

如何从文章中获取正文和文字?我的印象是使用了prop = extracts.

How do I get the body and text from my article? I was under the impression prop=extracts is what is used.

推荐答案

prop=extracts是TextExtracts扩展程序的一部分(以前是 MobileFrontend扩展).如果您没有安装该扩展程序,则将无法使用prop=extracts.

prop=extracts is part of TextExtracts extension (formerly MobileFrontend extension). If you don't have that extension installed, you won't be able to use prop=extracts.

这篇关于Mediawiki API错误:参数'prop'的无法识别的值:提取的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆