wiki 使用笔记

Wiki 安装:Linux(Redhat EL5.3)下安装配置MediaWiki

wiki配置:

配置文件:DefaultSettings.php  //权限等配置

左边导航条:/wiki/index.php/MediaWiki:Sidebar

* cc项目 //一级导航
** api|API文档
* navigation //导航
** mainpage|mainpage-description
** portal-url|portal
** currentevents-url|currentevents
** recentchanges-url|recentchanges
** randompage-url|randompage
** helppage|help
* SEARCH //搜索
* TOOLBOX //工具箱
* LANGUAGES

页面目录:

== API使用规范 ==

API调用基础文档

== 调用 API ==

API Server URL: https://api.xx.com/xx

== API列表 ==

{| class="mw-statistics-table"
|-
! 接口分类 || 接口名 || 描述
|-
! rowspan=1 | 用户接口
| ''[[users.reg]]'' || ''用户注册''。
|-
! rowspan=1 | 系统接口
| [[system.version]] || 版本检测,检测是否为最新版本。[已完成][完成初步测试]
|}

页面:

== 功能说明 ==
修改用户信息。 == 调用说明 ==
=== 请求方式 ===
POST
=== 请求地址 ===
http://api.xxx.com/v1/users/reg == 参数 ==
所有参数都需进行URL编码,编码时请遵守 [http://tools.ietf.org/html/rfc1738 RFC1738] {| class="mw-statistics-table"
|-
! 参数名 || 必填 || 类型 || 描述
|-
| uname || true || String || 用户名
|-
| pwd || true || String || 用户密码
|-
| 性别 || true || int || 用户性别
|-
| address || true || String || 常居地
|} == 返回结果 ==
=== 返回参数说明 ===
{| class="mw-statistics-table"
|-
! 参数名 || 必填 || 类型 || 描述
|-
| code || true || int || 状态码
|} === 返回JSON样例 === [{
"uid": 222332,
"name": "Ramos",
"sex": 1,
"star": 1,
"zidou": 1 "birthday": "2008-10-12",
"email_hash": " 650628530_9c6b2b93842c46155b75b14a34054924",
"tinyurl": " http://head.xiaonei.com/photos/tiny_10942g177.jpg",
"headurl": " http://head.xiaonei.com/photos/tiny_10942g177.jpg",
"mainurl": " http://head.xiaonei.com/photos/tiny_10942g177.jpg",
"hometown_location": {
"country": "中国",
"province": "四川",
"city": "乐山"
},
"work_history": [{
"company_name": "千橡",
"description": "优秀的公司",
"start_date": "2008-7-7",
"end_date": ""
}],
"university_history": [{
"name": " 北京第二外国语学院",
"year": 2003,
"department": " 人文学院"
}],
"hs_history": [{
"name": " 黑龙江省实验中学",
"grad_year": 1999
}],
}] === 错误代码释义 ===
详细信息请查看[[bl-api-error|常见错误码列表]]

自定义code:

== 描述 ==
API接口文档中自定义CODE对应的含义 == 举报类型 ==
: 举报类型码
:: 0 色情 == 意见反馈 ==
: 联系方式类别
:: 0 QQ == 消息类型 ==
: 消息类型码
:: 0 登录消息 == Success Code ==
: 成功状态码
:: 0 成功 == 性别类别 ==
: 性别对应码
:: 0 男
:: 1 女 == Star Code ==
: 12星座
:: 100 白羊座 == Error Code ==
: 常见错误
:: 11 失败或网络异常 : 登录相关
:: 21 用户不存在
上一篇:【github问题】error: src refspec master does not match any解决方法|please tell me who you are


下一篇:Wiki 安装部署