From 59d82c902960fe132b5f8cdf075406298ae46821 Mon Sep 17 00:00:00 2001 From: Developer Date: Mon, 30 Mar 2026 06:42:59 +0800 Subject: [PATCH] =?UTF-8?q?=20=E6=9B=B4=E6=96=B0CHANGELOG=E8=AE=B0?= =?UTF-8?q?=E5=BD=95=E7=A7=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 2 + ht/API_投票.md | 1315 ---- ht/API使用文档.md | 545 ++ ht/README.md | 143 - ht/admin.php | 20 - ht/admin/index.php | 276 - ht/admin/logs.php | 360 -- ht/admin/stat.php | 499 -- ht/admin/topic.php | 420 -- ht/admin/topic_form.php | 354 -- ht/admin/topic_options.php | 569 -- ht/admin/user.php | 698 --- ht/api.php | 317 + ht/api/admin.php | 379 -- ht/api/topic.php | 425 -- ht/api/upload.php | 203 - ht/api/user.php | 238 - ht/api/vote.php | 219 - .../2026-03-27-poetry-quiz-frontend-design.md | 111 - ht/inc/conn.php | 78 - ht/inc/css.css | 495 -- ht/inc/js.js | 458 -- ht/inc/pubs.php | 147 - ht/inc/sqls.php | 281 - ht/index.php | 696 +-- ht/login.php | 146 - ht/p1/API文档.md | 503 -- ht/p1/api.js | 344 -- ht/p1/api.php | 375 -- ht/p1/data/tzgsc.json | 5456 ----------------- ht/p1/index.php | 74 - ht/p1/style.css | 469 -- ht/p1/syx.php | 97 - ht/reger.php | 187 - ht/style.css | 545 ++ ht/tapi.php | 287 - ht/test/API.md | 525 -- ht/test/api.php | 353 -- ht/test/data/.htaccess | 5 - ht/test/data/questions.json | 4029 ------------ ht/test/index.html | 422 -- ht/uploads/img_69c3f26541236_20260325.jpg | Bin 46231 -> 0 bytes ht/vote.php | 650 -- ht/vote_api.php | 490 -- server_monitor.html | 418 -- server_monitor_api.php | 80 - 46 files changed, 1757 insertions(+), 22946 deletions(-) delete mode 100644 ht/API_投票.md create mode 100644 ht/API使用文档.md delete mode 100644 ht/README.md delete mode 100644 ht/admin.php delete mode 100644 ht/admin/index.php delete mode 100644 ht/admin/logs.php delete mode 100644 ht/admin/stat.php delete mode 100644 ht/admin/topic.php delete mode 100644 ht/admin/topic_form.php delete mode 100644 ht/admin/topic_options.php delete mode 100644 ht/admin/user.php create mode 100644 ht/api.php delete mode 100644 ht/api/admin.php delete mode 100644 ht/api/topic.php delete mode 100644 ht/api/upload.php delete mode 100644 ht/api/user.php delete mode 100644 ht/api/vote.php delete mode 100644 ht/docs/superpowers/specs/2026-03-27-poetry-quiz-frontend-design.md delete mode 100644 ht/inc/conn.php delete mode 100644 ht/inc/css.css delete mode 100644 ht/inc/js.js delete mode 100644 ht/inc/pubs.php delete mode 100644 ht/inc/sqls.php delete mode 100644 ht/login.php delete mode 100644 ht/p1/API文档.md delete mode 100644 ht/p1/api.js delete mode 100644 ht/p1/api.php delete mode 100644 ht/p1/data/tzgsc.json delete mode 100644 ht/p1/index.php delete mode 100644 ht/p1/style.css delete mode 100644 ht/p1/syx.php delete mode 100644 ht/reger.php create mode 100644 ht/style.css delete mode 100644 ht/tapi.php delete mode 100644 ht/test/API.md delete mode 100644 ht/test/api.php delete mode 100644 ht/test/data/.htaccess delete mode 100644 ht/test/data/questions.json delete mode 100644 ht/test/index.html delete mode 100644 ht/uploads/img_69c3f26541236_20260325.jpg delete mode 100644 ht/vote.php delete mode 100644 ht/vote_api.php delete mode 100644 server_monitor.html delete mode 100644 server_monitor_api.php diff --git a/CHANGELOG.md b/CHANGELOG.md index 278e7c9..02edf0b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,8 @@ All notable changes to this project will be documented in this file. --- + + ## [1.3.1] - 2026-03-29 ### 修复 diff --git a/ht/API_投票.md b/ht/API_投票.md deleted file mode 100644 index 51e480a..0000000 --- a/ht/API_投票.md +++ /dev/null @@ -1,1315 +0,0 @@ -# 投票系统 API 接口文档 - -## 概述 - -本文档描述了投票系统的所有API接口,包括用户管理、投票操作、投票主题管理、管理员功能和文件上传等功能。该API支持GET和POST两种请求方式,并支持JSON格式的请求体。 - -## 基础信息 - -- **基础URL**: `https://poe.vogov.cn/toupiao/` -- **请求方式**: GET / POST -- **数据格式**: JSON -- **字符编码**: UTF-8 -- **跨域支持**: 已启用CORS - -## 通用响应格式 - -所有接口返回统一的JSON格式: - -```json -{ - "code": 0, - "msg": "操作成功", - "data": {} -} -``` - -### 响应字段说明 - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| code | int | 状态码,0表示成功,非0表示失败 | -| msg | string | 提示信息 | -| data | object/array | 返回数据,具体内容根据接口而定 | - ---- - -# 数据库结构 - -## 1. 用户表 (tp_users) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int(11) | 用户ID,主键,自增 | -| username | varchar(255) | 用户账号(手机号/邮箱/微信号) | -| password | varchar(255) | 密码(加密存储) | -| irole | tinyint(1) | 角色(0:普通用户, 1:管理员) | -| status | tinyint(1) | 状态(0:禁用, 1:正常) | -| regtime | datetime | 注册时间 | -| logtime | datetime | 最后登录时间 | -| user_identifier | varchar(100) | 用户标识(可选) | - -## 2. 投票主题表 (tp_vote) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int(11) | 主题ID,主键,自增 | -| title | varchar(255) | 投票标题 | -| idesc | text | 投票描述 | -| statime | datetime | 开始时间 | -| endtime | datetime | 结束时间 | -| status | tinyint(1) | 状态(0:禁用, 1:正常) | -| itype | tinyint(1) | 类型(0:单选, 1:多选) | -| maxtime | int(11) | 多选时最多可选几项 | -| addtime | datetime | 创建时间 | -| adduser | int(11) | 创建用户ID | -| iview | int(11) | 查看次数 | - -## 3. 投票选项表 (tp_xuan) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int(11) | 选项ID,主键,自增 | -| topic_id | int(11) | 所属投票主题ID | -| name | varchar(255) | 选项名称 | -| idesc | text | 选项描述 | -| imgs | varchar(255) | 选项图片 | -| sort | int(11) | 排序值 | -| addtime | datetime | 创建时间 | -| adduser | int(11) | 创建用户ID | - -## 4. 投票记录表 (tp_recs) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int(11) | 记录ID,主键,自增 | -| topic_id | int(11) | 投票主题ID | -| user_id | int(11) | 用户ID | -| option_id | int(11) | 选项ID | -| vote_time | datetime | 投票时间 | -| ip | varchar(50) | 投票IP | - -## 5. 系统日志表 (tp_logs) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int(11) | 日志ID,主键,自增 | -| user_id | int(11) | 用户ID | -| action | varchar(50) | 操作类型 | -| idesc | text | 操作描述 | -| ip | varchar(50) | 操作IP | -| logtime | datetime | 操作时间 | - ---- - -# 一、用户API (tapi.php) - -**接口地址**: `/tapi.php` - -## 1.1 用户登录 - -**接口描述**: 用户使用账号(手机号/邮箱/微信号)和密码登录系统 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:login | -| username | string | 是 | 用户账号,支持手机号、邮箱或微信号 | -| password | string | 是 | 用户密码 | - -**请求示例**: - -``` -POST /tapi.php -Content-Type: application/json - -{ - "act": "login", - "username": "13800138000", - "password": "123456" -} -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "登录成功", - "data": { - "id": 1, - "username": "13800138000", - "irole": 0, - "status": 1, - "regtime": "2026-03-27 10:00:00", - "logtime": "2026-03-27 14:30:00", - "user_identifier": "user123" - } -} -``` - -**错误码说明**: - -| 错误码 | 说明 | -|--------|------| -| 1 | 账号和密码不能为空 | -| 1 | 账号或密码错误 | -| 1 | 账号已被禁用,请联系管理员 | - ---- - -## 1.2 用户注册 - -**接口描述**: 新用户注册账号,支持手机号、邮箱或微信号作为账号 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:register | -| username | string | 是 | 用户账号,支持手机号、邮箱或微信号 | -| password | string | 是 | 用户密码,长度不少于6位 | -| user_identifier | string | 否 | 用户标识(可选) | - -**账号格式要求**: - -- **手机号**: 以1开头,第二位为3-9,共11位数字 -- **邮箱**: 标准邮箱格式,如 user@example.com -- **微信号**: 6-20位字母、数字、下划线或连字符 - -**请求示例**: - -``` -POST /tapi.php -Content-Type: application/json - -{ - "act": "register", - "username": "13800138000", - "password": "123456", - "user_identifier": "user123" -} -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "注册成功", - "data": {} -} -``` - -**错误码说明**: - -| 错误码 | 说明 | -|--------|------| -| 1 | 账号和密码不能为空 | -| 1 | 请输入正确的手机号、邮箱或微信号 | -| 1 | 密码长度不能少于6位 | -| 1 | 该账号已被注册 | -| 1 | 注册失败,请稍后重试 | - ---- - -## 1.3 获取用户信息 - -**接口描述**: 获取当前登录用户的详细信息 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getUserInfo | - -**请求示例**: - -``` -GET /tapi.php?act=getUserInfo -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "获取成功", - "data": { - "id": 1, - "username": "13800138000", - "irole": 0, - "status": 1, - "regtime": "2026-03-27 10:00:00", - "logtime": "2026-03-27 14:30:00", - "user_identifier": "user123" - } -} -``` - -**注意**: 此接口需要用户已登录,否则会返回错误。 - ---- - -## 1.4 用户登出 - -**接口描述**: 用户退出登录,清除session - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:logout | - -**请求示例**: - -``` -GET /tapi.php?act=logout -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "登出成功", - "data": {} -} -``` - ---- - -## 1.5 更新用户标识 - -**接口描述**: 更新当前登录用户的标识信息 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:updateUserIdentifier | -| user_identifier | string | 否 | 用户标识(可选),长度不超过100个字符 | - -**请求示例**: - -``` -POST /tapi.php -Content-Type: application/json - -{ - "act": "updateUserIdentifier", - "user_identifier": "new_identifier" -} -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "更新成功", - "data": { - "id": 1, - "username": "13800138000", - "irole": 0, - "status": 1, - "regtime": "2026-03-27 10:00:00", - "logtime": "2026-03-27 14:30:00", - "user_identifier": "new_identifier" - } -} -``` - -**注意**: 此接口需要用户已登录,否则会返回错误。 - ---- - -# 二、投票API (vote_api.php) - -**接口地址**: `/vote_api.php` - -## 2.1 获取投票列表 - -**接口描述**: 获取投票列表,支持分页和筛选 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getVoteList | -| page | int | 否 | 当前页码,默认1 | -| pageSize | int | 否 | 每页记录数,默认10 | -| status | int | 否 | 状态筛选,-1表示全部,0表示禁用,1表示正常 | -| type | int | 否 | 类型筛选,-1表示全部,0表示单选,1表示多选 | - -**请求示例**: - -``` -GET /vote_api.php?act=getVoteList&page=1&pageSize=10 -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "获取成功", - "data": { - "list": [ - { - "id": 1, - "title": "最喜欢的水果", - "idesc": "请选择您最喜欢的水果", - "itype": 0, - "maxtime": 1, - "status": 1, - "iview": 14, - "addtime": "2026-03-25 22:25:46", - "statime": "2026-03-24 22:25:46", - "endtime": "2026-04-01 22:25:46", - "status_text": "进行中", - "status_class": "vote-status-active" - } - ], - "pagination": { - "total": 1, - "page": 1, - "pageSize": 10, - "totalPage": 1, - "offset": 0 - } - } -} -``` - -### 投票项字段说明 (VoteItem) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int | 投票ID | -| title | string | 投票标题 | -| idesc | string | 投票描述 | -| itype | int | 类型(0:单选, 1:多选) | -| maxtime | int | 多选时最多可选几项 | -| status | int | 状态(0:禁用, 1:正常) | -| iview | int | 查看次数 | -| addtime | string | 创建时间 | -| statime | string | 开始时间 | -| endtime | string | 结束时间 | -| status_text | string | 状态文本(进行中/已结束/未开始/已禁用) | -| status_class | string | 状态样式类 | - -### 状态说明 - -| status_text | status_class | 说明 | -|-------------|--------------|------| -| 进行中 | vote-status-active | 投票正在进行中 | -| 已结束 | vote-status-ended | 投票已结束 | -| 未开始 | vote-status-pending | 投票尚未开始 | -| 已禁用 | vote-status-disabled | 投票已被禁用 | - ---- - -## 2.2 获取投票详情 - -**接口描述**: 获取投票详情和选项信息 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getVoteDetail | -| id | int | 是 | 投票ID | - -**请求示例**: - -``` -GET /vote_api.php?act=getVoteDetail&id=1 -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "获取成功", - "data": { - "vote": { - "id": 1, - "title": "最喜欢的水果", - "idesc": "请选择您最喜欢的水果", - "itype": 0, - "maxtime": 1, - "status": 1, - "iview": 15, - "addtime": "2026-03-25 22:25:46", - "statime": "2026-03-24 22:25:46", - "endtime": "2026-04-01 22:25:46", - "status_text": "进行中", - "status_class": "vote-status-active" - }, - "options": [ - { - "id": 1, - "topic_id": 1, - "name": "苹果", - "idesc": "红富士苹果", - "imgs": "", - "sort": 0 - }, - { - "id": 2, - "topic_id": 1, - "name": "香蕉", - "idesc": "进口香蕉", - "imgs": "", - "sort": 1 - } - ], - "hasVoted": false, - "userVotes": [], - "canVote": true - } -} -``` - -### 响应字段说明 - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| vote | object | 投票详情 | -| options | array | 选项列表 | -| hasVoted | bool | 当前用户是否已投票 | -| userVotes | array | 当前用户已投的选项ID列表 | -| canVote | bool | 是否可以投票 | - -### 选项字段说明 (VoteOption) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int | 选项ID | -| topic_id | int | 所属投票主题ID | -| name | string | 选项名称 | -| idesc | string | 选项描述 | -| imgs | string | 选项图片URL | -| sort | int | 排序值 | - -**错误码说明**: - -| 错误码 | 说明 | -|--------|------| -| 1 | 参数错误 | -| 1 | 投票不存在 | - ---- - -## 2.3 提交投票 - -**接口描述**: 提交用户的投票选择 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:submitVote | -| topic_id | int | 是 | 投票ID | -| options | array/string | 是 | 选项ID数组或逗号分隔的字符串 | - -**请求示例**: - -``` -POST /vote_api.php -Content-Type: application/json - -{ - "act": "submitVote", - "topic_id": 1, - "options": [1, 2] -} -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "投票成功", - "data": {} -} -``` - -**错误码说明**: - -| 错误码 | 说明 | -|--------|------| -| 1 | 请先登录 | -| 1 | 参数错误 | -| 1 | 请至少选择一个选项 | -| 1 | 投票不存在 | -| 1 | 该投票已被禁用 | -| 1 | 该投票尚未开始 | -| 1 | 该投票已经结束 | -| 1 | 您已经参与过该投票 | -| 1 | 最多只能选择 X 项 | -| 1 | 选项不存在 | -| 1 | 提交投票失败 | - -**注意**: 此接口需要用户已登录,否则会返回错误。 - ---- - -## 2.4 获取投票结果 - -**接口描述**: 获取投票结果和统计数据 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getVoteResult | -| id | int | 是 | 投票ID | - -**请求示例**: - -``` -GET /vote_api.php?act=getVoteResult&id=1 -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "获取成功", - "data": { - "vote": { - "id": 1, - "title": "最喜欢的水果", - "idesc": "请选择您最喜欢的水果", - "itype": 0, - "maxtime": 1, - "status": 1, - "iview": 15, - "addtime": "2026-03-25 22:25:46", - "statime": "2026-03-24 22:25:46", - "endtime": "2026-04-01 22:25:46" - }, - "options": [ - { - "id": 1, - "name": "苹果", - "idesc": "红富士苹果", - "imgs": "", - "count": 50, - "percentage": 50 - }, - { - "id": 2, - "name": "香蕉", - "idesc": "进口香蕉", - "imgs": "", - "count": 30, - "percentage": 30 - }, - { - "id": 3, - "name": "橙子", - "idesc": "新鲜橙子", - "imgs": "", - "count": 20, - "percentage": 20 - } - ], - "totalVotes": 100, - "hasVoted": true, - "userVotes": [1] - } -} -``` - -### 结果选项字段说明 (VoteResultOption) - -| 字段名 | 类型 | 说明 | -|--------|------|------| -| id | int | 选项ID | -| name | string | 选项名称 | -| idesc | string | 选项描述 | -| imgs | string | 选项图片URL | -| count | int | 投票数量 | -| percentage | float | 投票百分比 | - -**错误码说明**: - -| 错误码 | 说明 | -|--------|------| -| 1 | 参数错误 | -| 1 | 投票不存在 | -| 1 | 暂无投票选项 | - ---- - -## 2.5 获取用户投票记录 - -**接口描述**: 获取用户参与过的投票记录 - -**请求方式**: GET / POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getUserVotes | -| page | int | 否 | 当前页码,默认1 | -| pageSize | int | 否 | 每页记录数,默认10 | - -**请求示例**: - -``` -GET /vote_api.php?act=getUserVotes&page=1&pageSize=10 -``` - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "获取成功", - "data": { - "list": [ - { - "id": 1, - "title": "最喜欢的水果", - "idesc": "请选择您最喜欢的水果", - "itype": 0, - "maxtime": 1, - "status": 1, - "iview": 15, - "addtime": "2026-03-25 22:25:46", - "statime": "2026-03-24 22:25:46", - "endtime": "2026-04-01 22:25:46", - "status_text": "进行中", - "status_class": "vote-status-active" - } - ], - "pagination": { - "total": 1, - "page": 1, - "pageSize": 10, - "totalPage": 1, - "offset": 0 - } - } -} -``` - -**注意**: 此接口需要用户已登录,否则会返回错误。 - ---- - -# 三、用户API (api/user.php) - -**接口地址**: `/api/user.php` - -## 3.1 用户登录 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:login | -| username | string | 是 | 用户账号 | -| password | string | 是 | 用户密码 | - ---- - -## 3.2 用户注册 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:register | -| username | string | 是 | 用户账号 | -| password | string | 是 | 用户密码 | -| user_identifier | string | 否 | 用户标识 | - ---- - -## 3.3 用户登出 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:logout | - -**注意**: 登出后会重定向到首页。 - ---- - -## 3.4 获取用户信息 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getUserInfo | - ---- - -## 3.5 更新用户信息(修改密码) - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:updateUserInfo | -| new_password | string | 是 | 新密码 | -| confirm_password | string | 是 | 确认密码 | - ---- - -## 3.6 更新用户标识 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:updateUserIdentifier | -| user_identifier | string | 否 | 用户标识 | - ---- - -# 四、投票操作API (api/vote.php) - -**接口地址**: `/api/vote.php` - -## 4.1 提交投票 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:submit | -| topic_id | int | 是 | 投票ID | -| options | string | 是 | 选项ID,多个用逗号分隔 | - ---- - -## 4.2 检查是否已投票 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:checkVoted | -| topic_id | int | 是 | 投票ID | - -**响应示例**: -```json -{ - "code": 0, - "msg": "查询成功", - "data": { - "hasVoted": true - } -} -``` - ---- - -## 4.3 获取投票结果 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getResult | -| topic_id | int | 是 | 投票ID | - ---- - -# 五、投票主题管理API (api/topic.php) - -**接口地址**: `/api/topic.php` - -**注意**: 大部分接口需要管理员权限 - -## 5.1 获取投票主题列表 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getList | -| page | int | 否 | 当前页码,默认1 | -| page_size | int | 否 | 每页记录数,默认10 | -| status | int | 否 | 状态筛选 | -| type | int | 否 | 类型筛选 | -| keyword | string | 否 | 关键词搜索 | - -**权限要求**: 管理员 - ---- - -## 5.2 获取投票主题详情 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getDetail | -| id | int | 是 | 投票ID | - ---- - -## 5.3 添加投票主题 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:add | -| title | string | 是 | 投票标题 | -| desc | string | 否 | 投票描述 | -| statime | string | 是 | 开始时间 | -| endtime | string | 是 | 结束时间 | -| type | int | 否 | 类型(0:单选, 1:多选),默认0 | -| maxtime | int | 否 | 多选时最多可选几项,默认1 | -| status | int | 否 | 状态,默认1 | - -**权限要求**: 管理员 - ---- - -## 5.4 更新投票主题 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:update | -| id | int | 是 | 投票ID | -| title | string | 是 | 投票标题 | -| desc | string | 否 | 投票描述 | -| statime | string | 是 | 开始时间 | -| endtime | string | 是 | 结束时间 | -| type | int | 否 | 类型 | -| maxtime | int | 否 | 多选时最多可选几项 | -| status | int | 否 | 状态 | - -**权限要求**: 管理员 - ---- - -## 5.5 删除投票主题 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:delete | -| id | int | 是 | 投票ID | - -**权限要求**: 管理员 - -**注意**: 删除投票主题会同时删除相关的选项和投票记录。 - ---- - -## 5.6 获取投票选项 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getOptions | -| topic_id | int | 是 | 投票ID | - ---- - -## 5.7 添加投票选项 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:addOption | -| topic_id | int | 是 | 投票ID | -| name | string | 是 | 选项名称 | -| imgs | string | 否 | 选项图片URL | -| desc | string | 否 | 选项描述 | -| sort | int | 否 | 排序值,默认0 | - -**权限要求**: 管理员 - ---- - -## 5.8 更新投票选项 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:updateOption | -| id | int | 是 | 选项ID | -| name | string | 是 | 选项名称 | -| imgs | string | 否 | 选项图片URL | -| desc | string | 否 | 选项描述 | -| sort | int | 否 | 排序值 | - -**权限要求**: 管理员 - ---- - -## 5.9 删除投票选项 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:deleteOption | -| id | int | 是 | 选项ID | - -**权限要求**: 管理员 - -**注意**: 删除选项会同时删除相关的投票记录。 - ---- - -# 六、管理员API (api/admin.php) - -**接口地址**: `/api/admin.php` - -**权限要求**: 所有接口都需要管理员权限 - -## 6.1 添加用户 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:addUser | -| username | string | 是 | 用户名(手机号) | -| password | string | 是 | 密码 | -| role | int | 否 | 角色(0:普通用户, 1:管理员),默认0 | - ---- - -## 6.2 更新用户信息 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:updateUser | -| id | int | 是 | 用户ID | -| role | int | 否 | 角色 | -| status | int | 否 | 状态 | - ---- - -## 6.3 重置用户密码 - -**请求方式**: POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:resetPassword | -| id | int | 是 | 用户ID | -| password | string | 是 | 新密码 | - ---- - -## 6.4 获取投票统计数据 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getVoteStats | -| topic_id | int | 否 | 投票ID,不传则返回所有投票统计 | - -**响应示例** (指定投票): -```json -{ - "code": 0, - "msg": "获取成功", - "data": { - "vote": { ... }, - "options": [ - { - "id": 1, - "name": "苹果", - "count": 50, - "percentage": 50 - } - ], - "totalVotes": 100, - "participants": [ - { - "username": "13800138000", - "vote_time": "2026-03-27 10:00:00", - "ip": "127.0.0.1" - } - ] - } -} -``` - ---- - -## 6.5 获取系统日志 - -**请求方式**: GET/POST - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| act | string | 是 | 操作类型,固定值:getLogs | -| page | int | 否 | 当前页码,默认1 | -| page_size | int | 否 | 每页记录数,默认20 | -| user_id | int | 否 | 用户ID筛选 | -| action | string | 否 | 操作类型筛选 | -| start_date | string | 否 | 开始日期 | -| end_date | string | 否 | 结束日期 | - ---- - -# 七、文件上传API (api/upload.php) - -**接口地址**: `/api/upload.php` - -**权限要求**: 需要用户登录 - -## 7.1 上传图片 - -**请求方式**: POST (multipart/form-data) - -**请求参数**: - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| image | file | 是 | 图片文件 | - -**支持的图片格式**: JPG, PNG, GIF, WEBP - -**文件大小限制**: 最大10MB - -**图片处理**: 宽度大于1280px的图片会自动调整为1024px宽度 - -**响应示例** (成功): -```json -{ - "code": 0, - "msg": "上传成功", - "data": { - "url": "uploads/img_123456789_20260329.jpg", - "width": 1024, - "height": 768 - } -} -``` - -**错误码说明**: - -| 错误码 | 说明 | -|--------|------| -| 1001 | 请先登录 | -| 1002 | 请求方法错误 | -| 1003 | 上传失败 | -| 1004 | 只允许上传JPG、PNG、GIF和WEBP格式的图片 | -| 1005 | 文件大小超过限制,最大允许10MB | -| 1006 | 无效的图片文件 | -| 1007 | 不支持的图片格式 | -| 1008 | 文件保存失败 | - ---- - -# 八、跨域支持 - -本API已启用CORS,支持跨域请求。相关响应头: - -``` -Access-Control-Allow-Origin: * -Access-Control-Allow-Methods: GET, POST, OPTIONS -Access-Control-Allow-Headers: Content-Type, Authorization -``` - -对于OPTIONS预检请求,API会直接返回200状态码。 - ---- - -# 九、注意事项 - -1. **Session管理**: 登录成功后,服务器会创建session,后续请求需要携带session cookie -2. **密码安全**: 密码使用PHP的password_hash()函数加密存储 -3. **参数验证**: 所有输入参数都经过安全过滤,防止SQL注入和XSS攻击 -4. **错误处理**: 所有接口都有完善的错误处理机制,返回明确的错误信息 -5. **日志记录**: 重要操作(登录、注册、登出、投票)都会记录到系统日志中 -6. **投票限制**: 每个用户对每个投票只能投一次 -7. **权限控制**: 管理员接口需要验证用户角色(irole=1) - ---- - -# 十、使用示例 - -## JavaScript (Fetch API) - -```javascript -// 登录示例 -fetch('https://poe.vogov.cn/toupiao/tapi.php', { - method: 'POST', - headers: { - 'Content-Type': 'application/json' - }, - body: JSON.stringify({ - act: 'login', - username: '13800138000', - password: '123456' - }), - credentials: 'include' // 携带cookie -}) -.then(response => response.json()) -.then(data => { - if (data.code === 0) { - console.log('登录成功', data.data); - } else { - console.error('登录失败', data.msg); - } -}); - -// 获取投票列表 -fetch('https://poe.vogov.cn/toupiao/vote_api.php?act=getVoteList&page=1&pageSize=10', { - credentials: 'include' -}) -.then(response => response.json()) -.then(data => { - if (data.code === 0) { - console.log('投票列表', data.data.list); - } -}); - -// 提交投票 -fetch('https://poe.vogov.cn/toupiao/vote_api.php', { - method: 'POST', - headers: { - 'Content-Type': 'application/json' - }, - body: JSON.stringify({ - act: 'submitVote', - topic_id: 1, - options: [1, 2] - }), - credentials: 'include' -}) -.then(response => response.json()) -.then(data => { - if (data.code === 0) { - console.log('投票成功'); - } -}); -``` - -## Flutter (Dio) - -```dart -import 'package:dio/dio.dart'; - -final dio = Dio(BaseOptions( - baseUrl: 'https://poe.vogov.cn/toupiao/', - headers: { - 'Content-Type': 'application/json', - }, -)); - -// 登录 -final response = await dio.post('tapi.php', data: { - 'act': 'login', - 'username': '13800138000', - 'password': '123456', -}); - -if (response.data['code'] == 0) { - print('登录成功: ${response.data['data']}'); -} - -// 获取投票列表 -final voteResponse = await dio.get('vote_api.php', queryParameters: { - 'act': 'getVoteList', - 'page': 1, - 'pageSize': 10, -}); - -if (voteResponse.data['code'] == 0) { - final list = voteResponse.data['data']['list']; - print('投票列表: $list'); -} -``` - ---- - -# 十一、版本历史 - -- **V1.3** (2026-03-29): 完善API文档,添加数据库结构说明,添加所有API接口详细文档 -- **V1.2** (2026-03-27): 添加了更新用户标识接口,允许用户在登录后更新自己的用户标识 -- **V1.1** (2026-03-27): 添加了用户标识字段(user_identifier),允许用户在注册时提供可选的用户标识 -- **V1.0** (2026-03-27): 初始版本,提供用户登录、注册、获取用户信息和登出功能 - ---- - -*最后更新时间: 2026-03-29* diff --git a/ht/API使用文档.md b/ht/API使用文档.md new file mode 100644 index 0000000..38ecc8b --- /dev/null +++ b/ht/API使用文档.md @@ -0,0 +1,545 @@ +# 诗词收录系统 - API 使用文档 + +## 概述 + +本文档描述诗词收录系统的 API 接口使用方法。 + +## 基础信息 + +- **API 地址**: `api.php` +- **请求方式**: GET/POST +- **返回格式**: JSON +- **字符编码**: UTF-8 + +## API 接口 + +### 1. 获取分类列表 + +获取所有可用的诗词分类。 + +**接口地址**: `api.php?api=categories` + +**请求方式**: GET + +**请求参数**: 无 + +**返回示例**: + +```json +{ + "ok": true, + "categories": [ + { + "id": "1", + "sid": "1", + "icon": "fa-paper-plane", + "catename": "诗词句", + "alias": null, + "create_time": "2026-03-12 04:17:50", + "update_time": "2026-03-13 02:12:54" + } + ], + "debug": { + "current_dir": "/www/wwwroot/yy.vogov.cn/api/app", + "categories_count": 3 + } +} +``` + +--- + +### 2. 检查诗词名称是否存在 + +检查指定的诗词名称是否已存在于数据库中(支持相似度检查)。 + +**接口地址**: `api.php?api=check-name` + +**请求方式**: POST + +**请求参数**: + +| 参数名 | 类型 | 必填 | 说明 | +|--------|------|------|------| +| name | string | 是 | 诗词名称/参考语句 | +| threshold | int | 否 | 相似度阈值(0-100),默认 80 | + +**请求示例**: + +```javascript +const formData = new FormData(); +formData.append('name', '盈盈一水间,脉脉不得语'); +formData.append('threshold', 80); + +const response = await fetch('api.php?api=check-name', { + method: 'POST', + body: formData +}); + +const data = await response.json(); +``` + +**返回示例**: + +**无相似内容**: +```json +{ + "ok": true, + "exists": false, + "similar_count": 0, + "max_similarity": 0, + "threshold": 80 +} +``` + +**发现相似内容**: +```json +{ + "ok": true, + "exists": true, + "similar_count": 2, + "max_similarity": 95, + "threshold": 80 +} +``` + +**返回字段说明**: + +| 字段名 | 类型 | 说明 | +|--------|------|------| +| ok | boolean | 请求是否成功 | +| exists | boolean | 是否存在相似内容,true=存在,false=不存在 | +| similar_count | int | 相似内容条数 | +| max_similarity | float | 最高相似度百分比(0-100) | +| threshold | int | 使用的相似度阈值 | + +--- + +### 3. 提交诗词收录申请 + +提交诗词收录申请到数据库。 + +**接口地址**: `api.php?api=submit` + +**请求方式**: POST + +**请求参数**: + +| 参数名 | 类型 | 必填 | 说明 | +|--------|------|------|------| +| name | string | 是 | 诗词名称/参考语句 | +| catename | string | 是 | 分类名称 | +| url | string | 是 | 诗人和标题 | +| keywords | string | 是 | 关键词,多个用逗号分隔 | +| introduce | string | 是 | 诗词介绍 | +| img | string | 否 | 平台/配图,默认值: 'default' | +| captcha | string | 是 | 人机验证码 | +| threshold | int | 否 | 相似度阈值(0-100),默认 80 | + +**请求示例**: + +```javascript +const formData = new FormData(); +formData.append('name', '盈盈一水间,脉脉不得语'); +formData.append('catename', '诗词句'); +formData.append('url', '古诗十九首'); +formData.append('keywords', '爱情,古诗,离别'); +formData.append('introduce', '《迢迢牵牛星》是产生于汉代的一首文人五言诗...'); +formData.append('img', 'iOS Swift'); +formData.append('captcha', '1234'); +formData.append('threshold', 80); + +const response = await fetch('api.php?api=submit', { + method: 'POST', + body: formData +}); + +const data = await response.json(); +``` + +**返回示例**: + +**成功**: +```json +{ + "ok": true, + "message": "✅ 提交成功!等待审核", + "debug": { + "input_data": {...}, + "insert_result": true, + "last_insert_id": "123" + } +} +``` + +**失败**: +```json +{ + "ok": false, + "error": "该诗词已存在!", + "debug": {...} +} +``` + +**返回字段说明**: + +| 字段名 | 类型 | 说明 | +|--------|------|------| +| ok | boolean | 请求是否成功 | +| message | string | 成功消息(仅成功时返回) | +| error | string | 错误消息(仅失败时返回) | +| debug | object | 调试信息 | + +--- + +## 在 App 中的使用方法 + +### Android (Kotlin) + +```kotlin +// 获取分类 +suspend fun getCategories(): List { + val response = OkHttpClient().newCall( + Request.Builder() + .url("https://your-domain.com/api.php?api=categories") + .build() + ).execute() + + val json = JSONObject(response.body?.string()) + val categoriesArray = json.getJSONArray("categories") + + val categories = mutableListOf() + for (i in 0 until categoriesArray.length()) { + val cat = categoriesArray.getJSONObject(i) + categories.add(Category(cat.getString("catename"))) + } + + return categories +} + +// 检查名称 +suspend fun checkName(name: String, threshold: Int = 80): CheckResult { + val formBody = FormBody.Builder() + .add("name", name) + .add("threshold", threshold.toString()) + .build() + + val response = OkHttpClient().newCall( + Request.Builder() + .url("https://your-domain.com/api.php?api=check-name") + .post(formBody) + .build() + ).execute() + + val json = JSONObject(response.body?.string()) + return CheckResult( + exists = json.getBoolean("exists"), + similarCount = json.getInt("similar_count"), + maxSimilarity = json.getDouble("max_similarity"), + threshold = json.getInt("threshold") + ) +} + +// 提交收录 +suspend fun submitPoem(data: PoemData): Boolean { + val formBody = FormBody.Builder() + .add("name", data.name) + .add("catename", data.catename) + .add("url", data.url) + .add("keywords", data.keywords) + .add("introduce", data.introduce) + .add("img", data.img ?: "default") + .add("captcha", data.captcha) + .add("threshold", data.threshold?.toString() ?: "80") + .build() + + val response = OkHttpClient().newCall( + Request.Builder() + .url("https://your-domain.com/api.php?api=submit") + .post(formBody) + .build() + ).execute() + + val json = JSONObject(response.body?.string()) + return json.getBoolean("ok") +} +``` + +### iOS (Swift) + +```swift +// 获取分类 +func getCategories(completion: @escaping ([String]?, Error?) -> Void) { + guard let url = URL(string: "https://your-domain.com/api.php?api=categories") else { + completion(nil, NSError(domain: "", code: 0, userInfo: [NSLocalizedDescriptionKey: "Invalid URL"])) + return + } + + URLSession.shared.dataTask(with: url) { data, response, error in + if let error = error { + completion(nil, error) + return + } + + guard let data = data else { + completion(nil, NSError(domain: "", code: 0, userInfo: [NSLocalizedDescriptionKey: "No data"])) + return + } + + do { + if let json = try JSONSerialization.jsonObject(with: data) as? [String: Any], + let categories = json["categories"] as? [[String: Any]] { + let categoryNames = categories.compactMap { $0["catename"] as? String } + completion(categoryNames, nil) + } + } catch { + completion(nil, error) + } + }.resume() +} + +// 检查名称 +func checkName(name: String, threshold: Int = 80, completion: @escaping (CheckResult?, Error?) -> Void) { + guard let apiUrl = URL(string: "https://your-domain.com/api.php?api=check-name") else { + completion(nil, NSError(domain: "", code: 0, userInfo: [NSLocalizedDescriptionKey: "Invalid URL"])) + return + } + + var request = URLRequest(url: apiUrl) + request.httpMethod = "POST" + + let parameters = [ + "name": name, + "threshold": "\(threshold)" + ] + + request.httpBody = parameters.percentEncoded() + + URLSession.shared.dataTask(with: request) { data, response, error in + if let error = error { + completion(nil, error) + return + } + + guard let data = data else { + completion(nil, NSError(domain: "", code: 0, userInfo: [NSLocalizedDescriptionKey: "No data"])) + return + } + + do { + if let json = try JSONSerialization.jsonObject(with: data) as? [String: Any], + let exists = json["exists"] as? Bool, + let similarCount = json["similar_count"] as? Int, + let maxSimilarity = json["max_similarity"] as? Double, + let threshold = json["threshold"] as? Int { + let result = CheckResult( + exists: exists, + similarCount: similarCount, + maxSimilarity: maxSimilarity, + threshold: threshold + ) + completion(result, nil) + } + } catch { + completion(nil, error) + } + }.resume() +} + +// 提交收录 +func submitPoem(name: String, catename: String, url: String, keywords: String, introduce: String, img: String?, captcha: String, threshold: Int = 80, completion: @escaping (Bool, String?) -> Void) { + guard let apiUrl = URL(string: "https://your-domain.com/api.php?api=submit") else { + completion(false, "Invalid URL") + return + } + + var request = URLRequest(url: apiUrl) + request.httpMethod = "POST" + + let parameters = [ + "name": name, + "catename": catename, + "url": url, + "keywords": keywords, + "introduce": introduce, + "img": img ?? "default", + "captcha": captcha, + "threshold": "\(threshold)" + ] + + request.httpBody = parameters.percentEncoded() + + URLSession.shared.dataTask(with: request) { data, response, error in + if let error = error { + completion(false, error.localizedDescription) + return + } + + guard let data = data else { + completion(false, "No data") + return + } + + do { + if let json = try JSONSerialization.jsonObject(with: data) as? [String: Any], + let ok = json["ok"] as? Bool { + let message = json["message"] as? String ?? json["error"] as? String + completion(ok, message) + } + } catch { + completion(false, error.localizedDescription) + } + }.resume() +} + +extension Dictionary { + func percentEncoded() -> Data? { + return map { key, value in + let escapedKey = "\(key)".addingPercentEncoding(withAllowedCharacters: .urlQueryValueAllowed) ?? "" + let escapedValue = "\(value)".addingPercentEncoding(withAllowedCharacters: .urlQueryValueAllowed) ?? "" + return escapedKey + "=" + escapedValue + } + .joined(separator: "&") + .data(using: .utf8) + } +} + +extension CharacterSet { + static let urlQueryValueAllowed: CharacterSet = { + let generalDelimitersToEncode = ":#[]@" + let subDelimitersToEncode = "!$&'()*+,;=" + + var allowed = CharacterSet.urlQueryAllowed + allowed.remove(charactersIn: "\(generalDelimitersToEncode)\(subDelimitersToEncode)") + return allowed + }() +} +``` + +### Flutter (Dart) + +```dart +import 'package:http/http.dart' as http; +import 'dart:convert'; + +// 获取分类 +Future> getCategories() async { + final response = await http.get( + Uri.parse('https://your-domain.com/api.php?api=categories'), + ); + + if (response.statusCode == 200) { + final data = json.decode(response.body); + final List categories = data['categories']; + return categories.map((cat) => cat['catename'] as String).toList(); + } else { + throw Exception('Failed to load categories'); + } +} + +// 检查名称 +Future checkName({ + required String name, + int threshold = 80, +}) async { + final response = await http.post( + Uri.parse('https://your-domain.com/api.php?api=check-name'), + body: { + 'name': name, + 'threshold': threshold.toString(), + }, + ); + + if (response.statusCode == 200) { + final data = json.decode(response.body); + return CheckResult( + exists: data['exists'] as bool, + similarCount: data['similar_count'] as int, + maxSimilarity: (data['max_similarity'] as num).toDouble(), + threshold: data['threshold'] as int, + ); + } else { + throw Exception('Failed to check name'); + } +} + +// 提交收录 +Future submitPoem({ + required String name, + required String catename, + required String url, + required String keywords, + required String introduce, + String? img, + required String captcha, + int threshold = 80, +}) async { + final response = await http.post( + Uri.parse('https://your-domain.com/api.php?api=submit'), + body: { + 'name': name, + 'catename': catename, + 'url': url, + 'keywords': keywords, + 'introduce': introduce, + 'img': img ?? 'default', + 'captcha': captcha, + 'threshold': threshold.toString(), + }, + ); + + if (response.statusCode == 200) { + final data = json.decode(response.body); + return data['ok'] as bool; + } else { + throw Exception('Failed to submit'); + } +} +``` + +--- + +## 错误码说明 + +| 错误信息 | 说明 | +|----------|------| +| 缺少必填字段:xxx | 必填字段未填写 | +| 该诗词已存在! | 诗词名称已在数据库中,或相似度超过阈值 | +| ❌ 数据库写入失败:无法插入数据 | 数据库插入失败 | +| 验证码错误,请重新输入 | 人机验证码错误 | +| 提交过于频繁,请稍后再试 | 频率限制,1分钟内只能提交3次 | + +--- + +## 相似度说明 + +系统使用 **Levenshtein 距离算法** 计算文本相似度: + +1. **文本清理**:自动去除标点符号和空格后比较 +2. **阈值设置**:0-100%,默认 80% +3. **判断规则**:相似度 ≥ 阈值 则认为是重复内容 + +**示例**: +- "盈盈一水间,脉脉不得语" +- "盈盈一水间,脉脉不得语。"(相似度约 95%) +- "盈盈一水间,脉脉不得"(相似度约 85%) + +--- + +## 注意事项 + +1. **字符编码**: 所有请求和响应都使用 UTF-8 编码 +2. **人机验证**: 提交接口必须提供正确的验证码 +3. **频率限制**: 同一 IP 1分钟内最多提交 3 次 +4. **相似度检查**: check-name 和 submit 接口都会进行相似度检查 +5. **数据安全**: 所有用户输入都会经过安全处理 +6. **调试信息**: API 返回包含 debug 字段,方便开发调试,生产环境可忽略 + +--- + +## 更新日志 + +- **v1.0.12**: 添加相似度验证功能,支持可配置阈值 +- **v1.0.11**: 修改验证表为 pre_site +- **v1.0.10**: 添加人机验证功能和频率限制 +- **v1.0.9**: 添加结果Modal对话框 +- **v1.0.8**: 添加检测按钮和提交前确认 diff --git a/ht/README.md b/ht/README.md deleted file mode 100644 index 11554b7..0000000 --- a/ht/README.md +++ /dev/null @@ -1,143 +0,0 @@ -# 查立得出品费心投票PHP+MySQL轻量级投票系统 - -一个简洁实用的投票系统,基于PHP7+MySQL5.6开发,使用原生代码实现,不依赖外部框架。 -非常适合初学者入门学习源码,及满足你的基本投票需求(初始1.0版本请测试可用再实际应用)。 - -## 功能特点 - -- 用户注册与登录(手机号为用户名) -- 投票主题创建与管理 -- 支持单选和多选投票 -- 投票结果实时统计与展示 -- 管理员后台管理 -- 日志记录与统计分析 - -## 安装说明 - -### 系统要求 - -- PHP 7.0及以上版本 -- MySQL 5.6及以上版本 -- Web服务器(如Apache、Nginx等)推荐宝塔环境 - -### 安装步骤 - -1. **准备数据库** - - 使用宝塔/phpMyAdmin等工具导入`install.sql`文件。 - -2. **配置数据库连接** - - 修改`inc/conn.php`文件中的数据库配置信息: - -3. **上传文件** - - 将所有文件上传到Web服务器的根目录或子目录。 - -4. **设置文件权限** - - 确保Web服务器对以下目录有写入权限: - - assets/img/(如果需要上传图片) - -5. **访问网站** - - 通过浏览器访问您的网站地址,系统已准备就绪。 - -## 默认账号 - -系统初始安装后,会自动创建一个管理员账号: - -- 用户名:13800000000 -- 密码:admin123 - -请登录后立即修改默认密码。 - -## 目录结构 - -``` -/toupiao/ - ├── index.php // 网站首页,显示投票列表 - ├── login.php // 登录页面 - ├── reger.php // 注册页面 - ├── vote.php // 投票页面 - ├── admin.php // 管理员面板入口 - ├── install.sql // 数据库安装脚本 - ├── inc/ // 公共文件目录 - │ ├── conn.php // 数据库连接及站点配置 - │ ├── pubs.php // 公共函数 - │ ├── js.js // 公共JS函数 - │ ├── css.css // 公共CSS样式 - │ └── sqls.php // 数据库操作类 - ├── admin/ // 管理功能目录 - │ ├── index.php // 管理后台首页 - │ ├── topic.php // 投票主题管理 - │ ├── topic_form.php // 投票主题编辑表单 - │ ├── topic_options.php // 投票选项管理 - │ ├── user.php // 用户管理 - │ ├── stat.php // 投票统计 - │ └── logs.php // 日志管理 - ├── api/ // 接口目录 - │ ├── topic.php // 投票主题相关接口 - │ ├── vote.php // 投票操作接口 - │ ├── user.php // 用户相关接口 - │ └── admin.php // 管理相关接口 - └── assets/ // 静态资源目录 - ├── css/ // 自定义CSS - ├── js/ // 自定义JS - └── img/ // 图片资源 -``` - -## 使用说明 - -### 前台用户 - -1. **注册/登录** - - 使用手机号注册新账号 - - 使用已注册的手机号和密码登录 - -2. **浏览投票** - - 在首页可以查看所有可用的投票 - - 可以按类型和状态筛选投票 - -3. **参与投票** - - 点击投票详情进入投票页面 - - 选择您喜欢的选项并提交 - - 提交后可以查看实时投票结果 - -4. **查看我的投票** - - 在"我的投票"页面查看已参与的投票 - -### 管理员 - -1. **管理投票** - - 创建新投票主题 - - 编辑现有投票的信息和状态 - - 为投票添加、编辑或删除选项 - -2. **用户管理** - - 查看用户列表 - - 添加新用户 - - 编辑用户角色和状态 - - 重置用户密码 - -3. **数据统计** - - 查看总体投票统计 - - 查看每个投票的详细统计 - - 查看参与用户明细 - -4. **日志管理** - - 查看系统操作日志 - - 按用户、操作类型和时间筛选日志 - - 导出日志数据 - -## 技术特点 - -- HTML5 + CSS3 + JavaScript原生代码实现 -- PHP7 面向对象编程 -- MySQL数据库优化设计 -- AJAX异步通信 -- 响应式页面设计,适配各种设备 - -## 联系方式 -初始1.0版本请测试可用再实际应用 -意见建议,BUG反馈,可联系15058593138@qq.com。 diff --git a/ht/admin.php b/ht/admin.php deleted file mode 100644 index da8afbf..0000000 --- a/ht/admin.php +++ /dev/null @@ -1,20 +0,0 @@ -count('users'); -// 2. 投票主题总数 -$totalTopics = $db->count('vote'); -// 3. 进行中的投票数 -$now = date('Y-m-d H:i:s'); -$activeTopics = $db->count('vote', "status = 1 AND statime <= '$now' AND endtime >= '$now'"); -// 4. 总投票记录数 -$totalVotes = $db->count('recs'); - -// 最近投票记录 -$recentVotes = []; -$sql = "SELECT r.*, u.username, v.title - FROM " . $db->table('recs') . " r - LEFT JOIN " . $db->table('users') . " u ON r.user_id = u.id - LEFT JOIN " . $db->table('vote') . " v ON r.topic_id = v.id - ORDER BY r.vote_time DESC LIMIT 10"; -$result = $db->query($sql); -if ($result) { - while ($row = $result->fetch_assoc()) { - $recentVotes[] = $row; - } -} - -// 最近操作日志 -$recentLogs = []; -$sql = "SELECT l.*, u.username - FROM " . $db->table('logs') . " l - LEFT JOIN " . $db->table('users') . " u ON l.user_id = u.id - ORDER BY l.logtime DESC LIMIT 10"; -$result = $db->query($sql); -if ($result) { - while ($row = $result->fetch_assoc()) { - $recentLogs[] = $row; - } -} - -// 页面标题 -$pageTitle = "管理后台"; -?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- - - - -
-
-

系统概况

-
- 欢迎您, -
-
- - -
-
-
-
用户总数
-
- -
-
-
投票主题总数
-
- -
-
-
进行中的投票
-
- -
-
-
总投票记录数
-
-
- - -
-

最近投票记录

- - - - - - - - - - - - - - - - - - - - - - - - - -
用户投票主题投票时间IP地址
暂无投票记录
-
- - -
-

最近操作日志

- - - - - - - - - - - - - - - - - - - - - - - - - - - -
用户操作类型操作内容IP地址时间
暂无操作日志
-
-
-
- - - - diff --git a/ht/admin/logs.php b/ht/admin/logs.php deleted file mode 100644 index 6df10a8..0000000 --- a/ht/admin/logs.php +++ /dev/null @@ -1,360 +0,0 @@ -getAll('users', '', 'id, username', 'id ASC'); - -// 获取所有操作类型,用于筛选 -$sql = "SELECT DISTINCT action FROM " . $db->table('logs'); -$result = $db->query($sql); -$actionTypes = []; - -if ($result) { - while ($row = $result->fetch_assoc()) { - $actionTypes[] = $row['action']; - } -} - -// 页面标题 -$pageTitle = "系统日志"; -?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- - - - -
-
-

系统日志

-
- -
-
- - -
-
-
-
- - -
-
- - -
-
- - -
-
- - -
-
- - -
-
-
-
- - -
-
-
加载中...
-
- - - -
-
-
- - - - - diff --git a/ht/admin/stat.php b/ht/admin/stat.php deleted file mode 100644 index a6b3040..0000000 --- a/ht/admin/stat.php +++ /dev/null @@ -1,499 +0,0 @@ -getAll('vote', '', 'id, title', 'addtime DESC'); - -// 页面标题 -$pageTitle = "数据统计"; -?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- - - - -
-
-

数据统计

-
- - -
-
-
- - -
-
- -
-
-
- - -
- -
- - -
- -
-
-
- - - - - diff --git a/ht/admin/topic.php b/ht/admin/topic.php deleted file mode 100644 index 531950d..0000000 --- a/ht/admin/topic.php +++ /dev/null @@ -1,420 +0,0 @@ -getOne('vote', "id = $id"); - if (!$vote) { - header('Location: topic.php'); - exit; - } - - include 'topic_form.php'; - break; - - // 管理选项页面 - case 'options': - $pageTitle = "管理选项"; - $id = isset($_GET['id']) ? intval($_GET['id']) : 0; - - if (!$id) { - header('Location: topic.php'); - exit; - } - - // 获取投票信息 - $vote = $db->getOne('vote', "id = $id"); - if (!$vote) { - header('Location: topic.php'); - exit; - } - - // 获取选项列表 - $options = $db->getAll('xuan', "topic_id = $id", '*', 'sort ASC, id ASC'); - - include 'topic_options.php'; - break; - - // 投票列表页面(默认) - default: - $pageTitle = "投票管理"; - - // 获取分页参数 - $page = isset($_GET['page']) ? intval($_GET['page']) : 1; - $pageSize = 10; - - // 获取筛选参数 - $status = isset($_GET['status']) ? intval($_GET['status']) : -1; - $type = isset($_GET['type']) ? intval($_GET['type']) : -1; - $keyword = isset($_GET['keyword']) ? safeFilter($_GET['keyword']) : ''; - - // 构建查询条件 - $whereConditions = []; - if ($status >= 0) { - $whereConditions[] = "status = $status"; - } - if ($type >= 0) { - $whereConditions[] = "itype = $type"; - } - if ($keyword) { - $whereConditions[] = "(title LIKE '%$keyword%' OR idesc LIKE '%$keyword%')"; - } - - $whereStr = !empty($whereConditions) ? implode(' AND ', $whereConditions) : ''; - - // 获取总记录数 - $total = $db->count('vote', $whereStr); - - // 计算分页信息 - $pagination = getPagination($total, $page, $pageSize); - - // 获取投票列表 - $orderBy = "addtime DESC"; - $limit = "{$pagination['offset']}, {$pagination['pageSize']}"; - $voteList = $db->getAll('vote', $whereStr, '*', $orderBy, $limit); - - // 页面标题 - $pageTitle = "投票管理"; - ?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- - - - -
-
-
- - -
-
-
-
- - -
-
- - -
-
- - -
-
- - 重置 - 添加投票 -
-
-
-
- - -
- - - - - - - - - - - - - - - - - $now) { - $voteStatus = '未开始'; - $statusClass = 'vote-status-pending'; - } elseif ($vote['endtime'] < $now) { - $voteStatus = '已结束'; - $statusClass = 'vote-status-ended'; - } else { - $voteStatus = '进行中'; - $statusClass = 'vote-status-active'; - } - } - ?> - - - - - - - - - - - - - - - - - - -
ID标题类型开始时间结束时间状态浏览量创建时间操作
- 查看 - 选项 - 编辑 - -
暂无投票数据
-
- - - -
-
- - - - - - 0, - 'title' => '', - 'idesc' => '', - 'statime' => date('Y-m-d H:i:s', strtotime('+1 hour')), - 'endtime' => date('Y-m-d H:i:s', strtotime('+7 days')), - 'itype' => 0, - 'maxtime' => 1, - 'status' => 1 -]; - -// 如果是编辑模式,加载现有数据 -if ($action == 'edit' && isset($vote)) { - $formData = array_merge($formData, $vote); -} -?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- - - - -
-
-

- -
- - -
-
- - - - -
- - -
- -
- - -
- -
- - -
- -
- - > -
- -
- - -
- -
- - -
- -
- - -
- -
- - 取消 -
-
-
-
-
- - - - - diff --git a/ht/admin/topic_options.php b/ht/admin/topic_options.php deleted file mode 100644 index d97eaf8..0000000 --- a/ht/admin/topic_options.php +++ /dev/null @@ -1,569 +0,0 @@ - - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- - - - -
-
-

管理投票选项

- -
- - -
-

-

类型:

-

时间:

-

状态:

-
- - -
-

现有选项(

- - - -
-
- - -
- -

- - -
<?php echo htmlspecialchars($option['name']); ?>
- - - -

- - -

排序:

-
- - -
-
-

暂无选项数据

-
-
- -
- - -
-

添加新选项

-
- - - -
- - -
- -
- -
- - -
- - -
- -
- - -
- -
- - -
- -
- - -
-
-
-
-
- - - - - diff --git a/ht/admin/user.php b/ht/admin/user.php deleted file mode 100644 index b7c346d..0000000 --- a/ht/admin/user.php +++ /dev/null @@ -1,698 +0,0 @@ -= 0) { - $whereConditions[] = "status = $status"; -} -if ($role >= 0) { - $whereConditions[] = "irole = $role"; -} -if ($keyword) { - $whereConditions[] = "username LIKE '%$keyword%'"; -} - -$whereStr = !empty($whereConditions) ? implode(' AND ', $whereConditions) : ''; - -// 获取总记录数 -$total = $db->count('users', $whereStr); - -// 计算分页信息 -$pagination = getPagination($total, $page, $pageSize); - -// 获取用户列表 -$orderBy = "id ASC"; -$limit = "{$pagination['offset']}, {$pagination['pageSize']}"; -$userList = $db->getAll('users', $whereStr, '*', $orderBy, $limit); - -// 页面标题 -$pageTitle = "用户管理"; -?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- - - - -
-
-

用户管理

-
- -
-
- - -
-
-
-
- - -
-
- - -
-
- - -
-
- - 重置 -
-
-
-
- - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID用户名角色状态注册时间最后登录操作
- - 管理员 - - 普通用户 - - - - 正常 - - 禁用 - - - - - - - - - - - - -
暂无用户数据
-
- - - -
-
- - - - - diff --git a/ht/api.php b/ht/api.php new file mode 100644 index 0000000..0255b4a --- /dev/null +++ b/ht/api.php @@ -0,0 +1,317 @@ + true, + 'num1' => $num1, + 'num2' => $num2 + ], JSON_UNESCAPED_UNICODE); + exit; + } + + if ($api === 'categories') { + try { + $categories = []; + $debug_info['DB_findAll_exists'] = method_exists($DB, 'findAll') ? 'yes' : 'no'; + + if ($DB && method_exists($DB, 'findAll')) { + $categories = $DB->findAll('category', '*', null, 'sid asc'); + $debug_info['categories_count'] = count($categories); + } + + if (empty($categories)) { + $categories = [ + ['catename' => '唐诗'], + ['catename' => '宋词'], + ['catename' => '元曲'], + ['catename' => '诗词句'], + ['catename' => '现代诗'] + ]; + $debug_info['used_fallback'] = 'yes'; + } + + echo json_encode([ + 'ok' => true, + 'categories' => $categories, + 'debug' => $debug_info + ], JSON_UNESCAPED_UNICODE); + } catch (Exception $e) { + $debug_info['exception'] = $e->getMessage(); + echo json_encode([ + 'ok' => true, + 'categories' => [ + ['catename' => '唐诗'], + ['catename' => '宋词'], + ['catename' => '元曲'], + ['catename' => '诗词句'], + ['catename' => '现代诗'] + ], + 'debug' => $debug_info + ], JSON_UNESCAPED_UNICODE); + } + exit; + } + + if ($api === 'check-name') { + if (!isset($_POST['name'])) { + echo json_encode(['ok' => false, 'error' => '缺少name参数']); + exit; + } + + try { + $name = trim($_POST['name']); + $exists = false; + $similar_count = 0; + $max_similarity = 0; + $threshold = isset($_POST['threshold']) ? intval($_POST['threshold']) : 80; + $threshold = max(0, min(100, $threshold)); + + if ($DB && method_exists($DB, 'findAll')) { + $tables_to_check = ['site', 'apply']; + + foreach ($tables_to_check as $table) { + $all_records = $DB->findAll($table, 'name'); + + if ($all_records) { + foreach ($all_records as $record) { + $db_name = trim($record['name']); + + if ($db_name === $name) { + $exists = true; + $max_similarity = 100; + $similar_count = 1; + break 2; + } + + $similarity = calculateSimilarity($name, $db_name); + if ($similarity >= $threshold) { + $similar_count++; + if ($similarity > $max_similarity) { + $max_similarity = $similarity; + } + } + } + } + } + } + + if ($max_similarity >= $threshold) { + $exists = true; + } + + echo json_encode([ + 'ok' => true, + 'exists' => $exists, + 'similar_count' => $similar_count, + 'max_similarity' => $max_similarity, + 'threshold' => $threshold + ], JSON_UNESCAPED_UNICODE); + } catch (Exception $e) { + echo json_encode([ + 'ok' => true, + 'exists' => false, + 'similar_count' => 0, + 'max_similarity' => 0, + 'threshold' => 80 + ], JSON_UNESCAPED_UNICODE); + } + exit; + } + + if ($api === 'submit') { + $submit_debug = []; + + session_start(); + $client_ip = $_SERVER['REMOTE_ADDR'] ?? 'unknown'; + $rate_limit_key = 'submit_rate_' . $client_ip; + + if (!isset($_SESSION[$rate_limit_key])) { + $_SESSION[$rate_limit_key] = []; + } + + $current_time = time(); + $_SESSION[$rate_limit_key] = array_filter($_SESSION[$rate_limit_key], function($time) use ($current_time) { + return ($current_time - $time) < 60; + }); + + if (count($_SESSION[$rate_limit_key]) >= 3) { + echo json_encode(['ok' => false, 'error' => '提交过于频繁,请稍后再试']); + exit; + } + + $required = ['name', 'catename', 'url', 'keywords', 'introduce', 'captcha']; + foreach ($required as $field) { + if (!isset($_POST[$field]) || empty(trim($_POST[$field]))) { + echo json_encode(['ok' => false, 'error' => "缺少必填字段:{$field}"]); + exit; + } + } + + $captcha = trim($_POST['captcha']); + $captcha_key = 'captcha_' . session_id(); + if (!isset($_SESSION[$captcha_key]) || $_SESSION[$captcha_key] != $captcha) { + echo json_encode(['ok' => false, 'error' => '验证码错误,请重新输入']); + exit; + } + unset($_SESSION[$captcha_key]); + + try { + $name = trim($_POST['name']); + $threshold = isset($_POST['threshold']) ? intval($_POST['threshold']) : 80; + $threshold = max(0, min(100, $threshold)); + + $similar_exists = false; + if ($DB && method_exists($DB, 'findAll')) { + $tables_to_check = ['site', 'apply']; + + foreach ($tables_to_check as $table) { + $all_records = $DB->findAll($table, 'name'); + + if ($all_records) { + foreach ($all_records as $record) { + $db_name = trim($record['name']); + + if ($db_name === $name) { + $similar_exists = true; + break 2; + } + + $similarity = calculateSimilarity($name, $db_name); + if ($similarity >= $threshold) { + $similar_exists = true; + break 2; + } + } + } + } + } + + if ($similar_exists) { + echo json_encode(['ok' => false, 'error' => '该诗词已存在!']); + exit; + } + $catename = trim($_POST['catename']); + $url = trim($_POST['url']); + $keywords = trim($_POST['keywords']); + $introduce = trim($_POST['introduce']); + $img = isset($_POST['img']) ? trim($_POST['img']) : 'default'; + + $submit_debug['input_data'] = [ + 'name' => $name, + 'catename' => $catename, + 'url' => $url, + 'keywords' => $keywords, + 'introduce' => $introduce, + 'img' => $img + ]; + + $data = [ + 'name' => $name, + 'img' => $img, + 'catename' => $catename, + 'url' => $url, + 'keywords' => $keywords, + 'introduce' => $introduce, + 'reject' => 0, + 'create_time' => date('Y-m-d H:i:s'), + 'update_time' => date('Y-m-d H:i:s') + ]; + + $submit_debug['insert_data'] = $data; + $submit_debug['DB_insert_exists'] = method_exists($DB, 'insert') ? 'yes' : 'no'; + + $result = false; + $db_error = ''; + if ($DB && method_exists($DB, 'insert')) { + $result = $DB->insert('apply', $data); + $submit_debug['insert_result'] = $result; + if (method_exists($DB, 'error')) { + $db_error = $DB->error(); + $submit_debug['db_error'] = $db_error; + } + if (method_exists($DB, 'lastInsertId')) { + $submit_debug['last_insert_id'] = $DB->lastInsertId(); + } + } + + if ($result) { + $_SESSION[$rate_limit_key][] = $current_time; + + echo json_encode([ + 'ok' => true, + 'message' => '✅ 提交成功!等待审核', + 'debug' => $submit_debug + ], JSON_UNESCAPED_UNICODE); + } else { + echo json_encode([ + 'ok' => false, + 'error' => '❌ 数据库写入失败:无法插入数据', + 'debug' => $submit_debug + ], JSON_UNESCAPED_UNICODE); + } + } catch (Exception $e) { + $submit_debug['exception'] = $e->getMessage(); + $submit_debug['trace'] = $e->getTraceAsString(); + echo json_encode([ + 'ok' => false, + 'error' => $e->getMessage(), + 'debug' => $submit_debug + ], JSON_UNESCAPED_UNICODE); + } + exit; + } +} + +function calculateSimilarity($str1, $str2) { + $str1 = preg_replace('/[^\p{L}\p{N}\s]/u', '', $str1); + $str2 = preg_replace('/[^\p{L}\p{N}\s]/u', '', $str2); + $str1 = preg_replace('/\s+/', '', $str1); + $str2 = preg_replace('/\s+/', '', $str2); + + $len1 = mb_strlen($str1, 'UTF-8'); + $len2 = mb_strlen($str2, 'UTF-8'); + + if ($len1 === 0 || $len2 === 0) { + return 0; + } + + $maxLen = max($len1, $len2); + $distance = levenshtein($str1, $str2); + + if ($distance === 0) { + return 100; + } + + $similarity = round((1 - $distance / $maxLen) * 100, 2); + return max(0, min(100, $similarity)); +} + +echo json_encode(['ok' => false, 'error' => '无效的API请求']); diff --git a/ht/api/admin.php b/ht/api/admin.php deleted file mode 100644 index f2d8edf..0000000 --- a/ht/api/admin.php +++ /dev/null @@ -1,379 +0,0 @@ -getOne('users', "username = '$username'"); - if ($existUser) { - ajaxReturn(1, '该手机号已被注册'); - } - - // 密码加密 - $hashedPassword = password_hash($password, PASSWORD_DEFAULT); - - // 添加用户 - $userId = $db->insert('users', [ - 'username' => $username, - 'password' => $hashedPassword, - 'irole' => $role, - 'status' => 1, - 'regtime' => date('Y-m-d H:i:s') - ]); - - if (!$userId) { - ajaxReturn(1, '添加失败,请稍后重试'); - } - - // 记录日志 - writeLog($admin['id'], 'add_user', "添加用户:$username"); - - ajaxReturn(0, '添加成功', ['id' => $userId]); - break; - - // 更新用户信息 - case 'updateUser': - // 验证管理员权限 - $admin = checkAuth('updateUser', true); - if (!$admin) { - exit; - } - - // 获取参数 - $id = isset($_POST['id']) ? intval($_POST['id']) : 0; - $role = isset($_POST['role']) ? intval($_POST['role']) : null; - $status = isset($_POST['status']) ? intval($_POST['status']) : null; - - // 参数验证 - if (empty($id)) { - ajaxReturn(1, '参数错误'); - } - - // 获取用户信息 - $targetUser = $db->getOne('users', "id = $id"); - if (!$targetUser) { - ajaxReturn(1, '用户不存在'); - } - - // 不能禁用自己的账号 - if ($id == $admin['id'] && $status === 0) { - ajaxReturn(1, '不能禁用当前登录的账号'); - } - - // 准备更新数据 - $updateData = []; - - if ($role !== null) { - $updateData['irole'] = $role; - } - - if ($status !== null) { - $updateData['status'] = $status; - } - - if (empty($updateData)) { - ajaxReturn(1, '没有要更新的数据'); - } - - // 更新用户信息 - $result = $db->update('users', $updateData, "id = $id"); - if (!$result) { - ajaxReturn(1, '更新失败,请稍后重试'); - } - - // 记录日志 - $logContent = "更新用户信息:" . $targetUser['username']; - writeLog($admin['id'], 'update_user', $logContent); - - ajaxReturn(0, '更新成功'); - break; - - // 重置用户密码 - case 'resetPassword': - // 验证管理员权限 - $admin = checkAuth('resetPassword', true); - if (!$admin) { - exit; - } - - // 获取参数 - $id = isset($_POST['id']) ? intval($_POST['id']) : 0; - $password = isset($_POST['password']) ? $_POST['password'] : ''; - - // 参数验证 - if (empty($id) || empty($password)) { - ajaxReturn(1, '参数错误'); - } - - // 验证密码长度 - if (strlen($password) < 6) { - ajaxReturn(1, '密码长度不能少于6位'); - } - - // 获取用户信息 - $targetUser = $db->getOne('users', "id = $id"); - if (!$targetUser) { - ajaxReturn(1, '用户不存在'); - } - - // 密码加密 - $hashedPassword = password_hash($password, PASSWORD_DEFAULT); - - // 更新密码 - $result = $db->update('users', [ - 'password' => $hashedPassword - ], "id = $id"); - - if (!$result) { - ajaxReturn(1, '重置失败,请稍后重试'); - } - - // 记录日志 - $logContent = "重置用户密码:" . $targetUser['username']; - writeLog($admin['id'], 'reset_password', $logContent); - - ajaxReturn(0, '密码重置成功'); - break; - - // 获取投票统计数据 - case 'getVoteStats': - // 验证管理员权限 - $admin = checkAuth('getVoteStats', true); - if (!$admin) { - exit; - } - - // 获取参数 - $topicId = isset($_REQUEST['topic_id']) ? intval($_REQUEST['topic_id']) : 0; - - // 如果指定了特定投票 - if ($topicId) { - // 获取投票信息 - $vote = $db->getOne('vote', "id = $topicId"); - if (!$vote) { - ajaxReturn(1, '投票不存在'); - } - - // 获取选项列表 - $options = $db->getAll('xuan', "topic_id = $topicId", '*', 'sort ASC, id ASC'); - - // 获取每个选项的投票数 - $voteCounts = []; - $sql = "SELECT option_id, COUNT(*) as vote_count FROM " . $db->table('recs') . " WHERE topic_id = $topicId GROUP BY option_id"; - $result = $db->query($sql); - - if ($result) { - while ($row = $result->fetch_assoc()) { - $voteCounts[$row['option_id']] = $row['vote_count']; - } - } - - // 统计总票数 - $totalVotes = array_sum($voteCounts); - - // 格式化选项数据 - $formattedOptions = []; - foreach ($options as $option) { - $count = isset($voteCounts[$option['id']]) ? $voteCounts[$option['id']] : 0; - $percentage = $totalVotes > 0 ? round(($count / $totalVotes) * 100, 1) : 0; - - $formattedOptions[] = [ - 'id' => $option['id'], - 'name' => $option['name'], - 'count' => $count, - 'percentage' => $percentage - ]; - } - - // 获取参与用户 - $participants = []; - $sql = "SELECT DISTINCT u.username, r.vote_time, r.ip - FROM " . $db->table('recs') . " r - LEFT JOIN " . $db->table('users') . " u ON r.user_id = u.id - WHERE r.topic_id = $topicId - ORDER BY r.vote_time DESC"; - $result = $db->query($sql); - - if ($result) { - while ($row = $result->fetch_assoc()) { - $participants[] = [ - 'username' => $row['username'], - 'vote_time' => $row['vote_time'], - 'ip' => $row['ip'] - ]; - } - } - - ajaxReturn(0, '获取成功', [ - 'vote' => $vote, - 'options' => $formattedOptions, - 'totalVotes' => $totalVotes, - 'participants' => $participants - ]); - } else { - // 获取所有投票的统计信息 - $voteStats = []; - - // 获取所有投票 - $votes = $db->getAll('vote', '', '*', 'addtime DESC'); - - foreach ($votes as $vote) { - // 获取该投票的总票数 - $totalVotes = $db->count('recs', "topic_id = {$vote['id']}"); - - // 获取参与人数 - $sql = "SELECT COUNT(DISTINCT user_id) as user_count FROM " . $db->table('recs') . " WHERE topic_id = {$vote['id']}"; - $result = $db->query($sql); - $userCount = 0; - - if ($result && $row = $result->fetch_assoc()) { - $userCount = $row['user_count']; - } - - $voteStats[] = [ - 'id' => $vote['id'], - 'title' => $vote['title'], - 'start_time' => $vote['statime'], - 'end_time' => $vote['endtime'], - 'total_votes' => $totalVotes, - 'user_count' => $userCount, - 'view_count' => $vote['iview'] - ]; - } - - ajaxReturn(0, '获取成功', [ - 'voteStats' => $voteStats - ]); - } - break; - - // 获取系统日志 - case 'getLogs': - // 验证管理员权限 - $admin = checkAuth('getLogs', true); - if (!$admin) { - exit; - } - - // 获取分页参数 - $page = isset($_REQUEST['page']) ? intval($_REQUEST['page']) : 1; - $pageSize = isset($_REQUEST['page_size']) ? intval($_REQUEST['page_size']) : 20; - - // 获取筛选参数 - $userId = isset($_REQUEST['user_id']) ? intval($_REQUEST['user_id']) : 0; - $action = isset($_REQUEST['action']) ? safeFilter($_REQUEST['action']) : ''; - $startDate = isset($_REQUEST['start_date']) ? $_REQUEST['start_date'] : ''; - $endDate = isset($_REQUEST['end_date']) ? $_REQUEST['end_date'] : ''; - - // 构建查询条件 - $whereConditions = []; - - if ($userId) { - $whereConditions[] = "user_id = $userId"; - } - - if ($action) { - $whereConditions[] = "action = '$action'"; - } - - if ($startDate) { - $whereConditions[] = "logtime >= '$startDate 00:00:00'"; - } - - if ($endDate) { - $whereConditions[] = "logtime <= '$endDate 23:59:59'"; - } - - $whereStr = !empty($whereConditions) ? implode(' AND ', $whereConditions) : ''; - - // 获取总记录数 - $total = $db->count('logs', $whereStr); - - // 计算分页信息 - $pagination = getPagination($total, $page, $pageSize); - - // 获取日志列表 - $orderBy = "logtime DESC"; - $limit = "{$pagination['offset']}, {$pagination['pageSize']}"; - - $sql = "SELECT l.*, u.username - FROM " . $db->table('logs') . " l - LEFT JOIN " . $db->table('users') . " u ON l.user_id = u.id - " . ($whereStr ? "WHERE $whereStr" : "") . " - ORDER BY $orderBy - LIMIT $limit"; - - $result = $db->query($sql); - $logs = []; - - if ($result) { - while ($row = $result->fetch_assoc()) { - $logs[] = $row; - } - } - - // 获取所有操作类型,用于筛选 - $sql = "SELECT DISTINCT action FROM " . $db->table('logs'); - $result = $db->query($sql); - $actionTypes = []; - - if ($result) { - while ($row = $result->fetch_assoc()) { - $actionTypes[] = $row['action']; - } - } - - ajaxReturn(0, '获取成功', [ - 'logs' => $logs, - 'pagination' => $pagination, - 'actionTypes' => $actionTypes - ]); - break; - - // 未知操作 - default: - ajaxReturn(1, '未知操作'); - break; -} diff --git a/ht/api/topic.php b/ht/api/topic.php deleted file mode 100644 index 3dedbff..0000000 --- a/ht/api/topic.php +++ /dev/null @@ -1,425 +0,0 @@ -count('vote', $whereStr); - - // 计算分页信息 - $pagination = getPagination($total, $page, $pageSize); - - // 获取投票列表 - $orderBy = "addtime DESC"; - $limit = "{$pagination['offset']}, {$pagination['pageSize']}"; - $voteList = $db->getAll('vote', $whereStr, '*', $orderBy, $limit); - - // 格式化日期 - foreach ($voteList as &$vote) { - $vote['statime_formatted'] = date('Y-m-d H:i', strtotime($vote['statime'])); - $vote['endtime_formatted'] = date('Y-m-d H:i', strtotime($vote['endtime'])); - $vote['addtime_formatted'] = date('Y-m-d H:i', strtotime($vote['addtime'])); - } - - ajaxReturn(0, '获取成功', [ - 'list' => $voteList, - 'pagination' => $pagination - ]); - break; - - // 获取投票主题详情 - case 'getDetail': - // 获取参数 - $id = isset($_REQUEST['id']) ? intval($_REQUEST['id']) : 0; - - // 参数验证 - if (empty($id)) { - ajaxReturn(1, '参数错误'); - } - - // 获取投票详情 - $vote = $db->getOne('vote', "id = $id"); - if (!$vote) { - ajaxReturn(1, '投票不存在'); - } - - // 获取选项列表 - $options = $db->getAll('xuan', "topic_id = $id", '*', 'sort ASC, id ASC'); - - ajaxReturn(0, '获取成功', [ - 'vote' => $vote, - 'options' => $options - ]); - break; - - // 添加投票主题 - case 'add': - // 验证管理员权限 - $user = checkAuth('add', true); - if (!$user) { - exit; - } - - // 获取参数 - $title = isset($_POST['title']) ? safeFilter($_POST['title']) : ''; - $desc = isset($_POST['desc']) ? safeFilter($_POST['desc']) : ''; - $statime = isset($_POST['statime']) ? $_POST['statime'] : ''; - $endtime = isset($_POST['endtime']) ? $_POST['endtime'] : ''; - $type = isset($_POST['type']) ? intval($_POST['type']) : 0; - $maxtime = isset($_POST['maxtime']) ? intval($_POST['maxtime']) : 1; - $status = isset($_POST['status']) ? intval($_POST['status']) : 1; - - // 参数验证 - if (empty($title)) { - ajaxReturn(1, '请输入投票标题'); - } - - if (empty($statime) || empty($endtime)) { - ajaxReturn(1, '请选择开始和结束时间'); - } - - if (strtotime($statime) >= strtotime($endtime)) { - ajaxReturn(1, '结束时间必须晚于开始时间'); - } - - if ($type == 1 && $maxtime < 2) { - ajaxReturn(1, '多选投票最少可选2项'); - } - - // 添加投票主题 - $topicId = $db->insert('vote', [ - 'title' => $title, - 'idesc' => $desc, - 'statime' => $statime, - 'endtime' => $endtime, - 'itype' => $type, - 'maxtime' => $maxtime, - 'status' => $status, - 'addtime' => date('Y-m-d H:i:s'), - 'adduser' => $user['id'], - 'iview' => 0 - ]); - - if (!$topicId) { - ajaxReturn(1, '添加失败,请稍后重试'); - } - - // 记录日志 - writeLog($user['id'], 'add_topic', "添加投票:$title"); - - ajaxReturn(0, '添加成功', ['id' => $topicId]); - break; - - // 更新投票主题 - case 'update': - // 验证管理员权限 - $user = checkAuth('update', true); - if (!$user) { - exit; - } - - // 获取参数 - $id = isset($_POST['id']) ? intval($_POST['id']) : 0; - $title = isset($_POST['title']) ? safeFilter($_POST['title']) : ''; - $desc = isset($_POST['desc']) ? safeFilter($_POST['desc']) : ''; - $statime = isset($_POST['statime']) ? $_POST['statime'] : ''; - $endtime = isset($_POST['endtime']) ? $_POST['endtime'] : ''; - $type = isset($_POST['type']) ? intval($_POST['type']) : 0; - $maxtime = isset($_POST['maxtime']) ? intval($_POST['maxtime']) : 1; - $status = isset($_POST['status']) ? intval($_POST['status']) : 1; - - // 参数验证 - if (empty($id)) { - ajaxReturn(1, '参数错误'); - } - - if (empty($title)) { - ajaxReturn(1, '请输入投票标题'); - } - - if (empty($statime) || empty($endtime)) { - ajaxReturn(1, '请选择开始和结束时间'); - } - - if (strtotime($statime) >= strtotime($endtime)) { - ajaxReturn(1, '结束时间必须晚于开始时间'); - } - - if ($type == 1 && $maxtime < 2) { - ajaxReturn(1, '多选投票最少可选2项'); - } - - // 检查投票是否存在 - $vote = $db->getOne('vote', "id = $id"); - if (!$vote) { - ajaxReturn(1, '投票不存在'); - } - - // 更新投票主题 - $result = $db->update('vote', [ - 'title' => $title, - 'idesc' => $desc, - 'statime' => $statime, - 'endtime' => $endtime, - 'itype' => $type, - 'maxtime' => $maxtime, - 'status' => $status - ], "id = $id"); - - if (!$result) { - ajaxReturn(1, '更新失败,请稍后重试'); - } - - // 记录日志 - writeLog($user['id'], 'update_topic', "更新投票:$title"); - - ajaxReturn(0, '更新成功'); - break; - - // 删除投票主题 - case 'delete': - // 验证管理员权限 - $user = checkAuth('delete', true); - if (!$user) { - exit; - } - - // 获取参数 - $id = isset($_POST['id']) ? intval($_POST['id']) : 0; - - // 参数验证 - if (empty($id)) { - ajaxReturn(1, '参数错误'); - } - - // 检查投票是否存在 - $vote = $db->getOne('vote', "id = $id"); - if (!$vote) { - ajaxReturn(1, '投票不存在'); - } - - // 开始事务 - $db->startTransaction(); - - try { - // 删除相关记录 - $db->delete('recs', "topic_id = $id"); - $db->delete('xuan', "topic_id = $id"); - $db->delete('vote', "id = $id"); - - // 记录日志 - writeLog($user['id'], 'delete_topic', "删除投票:{$vote['title']}"); - - // 提交事务 - $db->commit(); - - ajaxReturn(0, '删除成功'); - } catch (Exception $e) { - // 回滚事务 - $db->rollback(); - ajaxReturn(1, '删除失败:' . $e->getMessage()); - } - break; - - // 获取投票选项 - case 'getOptions': - // 获取参数 - $topicId = isset($_REQUEST['topic_id']) ? intval($_REQUEST['topic_id']) : 0; - - // 参数验证 - if (empty($topicId)) { - ajaxReturn(1, '参数错误'); - } - - // 获取选项列表 - $options = $db->getAll('xuan', "topic_id = $topicId", '*', 'sort ASC, id ASC'); - - ajaxReturn(0, '获取成功', $options); - break; - - // 添加投票选项 - case 'addOption': - // 验证管理员权限 - $user = checkAuth('addOption', true); - if (!$user) { - exit; - } - - // 获取参数 - $topicId = isset($_POST['topic_id']) ? intval($_POST['topic_id']) : 0; - $name = isset($_POST['name']) ? safeFilter($_POST['name']) : ''; - $imgs = isset($_POST['imgs']) ? safeFilter($_POST['imgs']) : ''; - $desc = isset($_POST['desc']) ? safeFilter($_POST['desc']) : ''; - $sort = isset($_POST['sort']) ? intval($_POST['sort']) : 0; - - // 参数验证 - if (empty($topicId) || empty($name)) { - ajaxReturn(1, '请填写必要参数'); - } - - // 检查投票是否存在 - $vote = $db->getOne('vote', "id = $topicId"); - if (!$vote) { - ajaxReturn(1, '投票不存在'); - } - - // 添加选项 - $optionId = $db->insert('xuan', [ - 'topic_id' => $topicId, - 'name' => $name, - 'imgs' => $imgs, - 'idesc' => $desc, - 'sort' => $sort, - 'addtime' => date('Y-m-d H:i:s'), - 'adduser' => $user['id'] - ]); - - if (!$optionId) { - ajaxReturn(1, '添加失败,请稍后重试'); - } - - // 记录日志 - writeLog($user['id'], 'add_option', "添加投票选项:$name"); - - ajaxReturn(0, '添加成功', ['id' => $optionId]); - break; - - // 更新投票选项 - case 'updateOption': - // 验证管理员权限 - $user = checkAuth('updateOption', true); - if (!$user) { - exit; - } - - // 获取参数 - $id = isset($_POST['id']) ? intval($_POST['id']) : 0; - $name = isset($_POST['name']) ? safeFilter($_POST['name']) : ''; - $imgs = isset($_POST['imgs']) ? safeFilter($_POST['imgs']) : ''; - $desc = isset($_POST['desc']) ? safeFilter($_POST['desc']) : ''; - $sort = isset($_POST['sort']) ? intval($_POST['sort']) : 0; - - // 参数验证 - if (empty($id) || empty($name)) { - ajaxReturn(1, '请填写必要参数'); - } - - // 检查选项是否存在 - $option = $db->getOne('xuan', "id = $id"); - if (!$option) { - ajaxReturn(1, '选项不存在'); - } - - // 更新选项 - $result = $db->update('xuan', [ - 'name' => $name, - 'imgs' => $imgs, - 'idesc' => $desc, - 'sort' => $sort - ], "id = $id"); - - if (!$result) { - ajaxReturn(1, '更新失败,请稍后重试'); - } - - // 记录日志 - writeLog($user['id'], 'update_option', "更新投票选项:$name"); - - ajaxReturn(0, '更新成功'); - break; - - // 删除投票选项 - case 'deleteOption': - // 验证管理员权限 - $user = checkAuth('deleteOption', true); - if (!$user) { - exit; - } - - // 获取参数 - $id = isset($_POST['id']) ? intval($_POST['id']) : 0; - - // 参数验证 - if (empty($id)) { - ajaxReturn(1, '参数错误'); - } - - // 检查选项是否存在 - $option = $db->getOne('xuan', "id = $id"); - if (!$option) { - ajaxReturn(1, '选项不存在'); - } - - // 开始事务 - $db->startTransaction(); - - try { - // 删除投票记录 - $db->delete('recs', "option_id = $id"); - - // 删除选项 - $db->delete('xuan', "id = $id"); - - // 记录日志 - writeLog($user['id'], 'delete_option', "删除投票选项:{$option['name']}"); - - // 提交事务 - $db->commit(); - - ajaxReturn(0, '删除成功'); - } catch (Exception $e) { - // 回滚事务 - $db->rollback(); - ajaxReturn(1, '删除失败:' . $e->getMessage()); - } - break; - - // 未知操作 - default: - ajaxReturn(1, '未知操作'); - break; -} diff --git a/ht/api/upload.php b/ht/api/upload.php deleted file mode 100644 index 2088a1a..0000000 --- a/ht/api/upload.php +++ /dev/null @@ -1,203 +0,0 @@ - 1001, - 'msg' => '请先登录' - ])); -} - -// 检查请求方法 -if ($_SERVER['REQUEST_METHOD'] !== 'POST') { - exit(json_encode([ - 'code' => 1002, - 'msg' => '请求方法错误' - ])); -} - -// 检查是否有文件上传 -if (!isset($_FILES['image']) || $_FILES['image']['error'] !== UPLOAD_ERR_OK) { - exit(json_encode([ - 'code' => 1003, - 'msg' => '上传失败: ' . uploadErrorMessage($_FILES['image']['error']) - ])); -} - -// 验证文件类型 -$allowedTypes = ['image/jpeg', 'image/png', 'image/gif', 'image/webp']; -$fileType = $_FILES['image']['type']; - -if (!in_array($fileType, $allowedTypes)) { - exit(json_encode([ - 'code' => 1004, - 'msg' => '只允许上传JPG、PNG、GIF和WEBP格式的图片' - ])); -} - -// 验证文件大小(最大10MB) -$maxFileSize = 10 * 1024 * 1024; // 10MB -if ($_FILES['image']['size'] > $maxFileSize) { - exit(json_encode([ - 'code' => 1005, - 'msg' => '文件大小超过限制,最大允许10MB' - ])); -} - -// 准备上传路径 -$uploadDir = '../uploads/'; -if (!file_exists($uploadDir)) { - mkdir($uploadDir, 0777, true); -} - -// 生成唯一文件名 -$extension = pathinfo($_FILES['image']['name'], PATHINFO_EXTENSION); -$fileName = uniqid('img_') . '_' . date('Ymd') . '.' . $extension; -$uploadPath = $uploadDir . $fileName; -$relativeUrl = 'uploads/' . $fileName; - -// 处理图片上传 -$uploaded = false; - -// 获取图片信息 -$imageInfo = getimagesize($_FILES['image']['tmp_name']); -if (!$imageInfo) { - exit(json_encode([ - 'code' => 1006, - 'msg' => '无效的图片文件' - ])); -} - -$width = $imageInfo[0]; -$height = $imageInfo[1]; - -// 如果图片宽度大于1280,则调整为1024宽度(尽管前端已经处理,这里作为后端保障) -if ($width > 1280) { - // 计算新高度,保持比例 - $newWidth = 1024; - $newHeight = intval($height * ($newWidth / $width)); - - // 根据图片类型创建图像 - switch ($imageInfo[2]) { - case IMAGETYPE_JPEG: - $source = imagecreatefromjpeg($_FILES['image']['tmp_name']); - break; - case IMAGETYPE_PNG: - $source = imagecreatefrompng($_FILES['image']['tmp_name']); - break; - case IMAGETYPE_GIF: - $source = imagecreatefromgif($_FILES['image']['tmp_name']); - break; - case IMAGETYPE_WEBP: - $source = imagecreatefromwebp($_FILES['image']['tmp_name']); - break; - default: - exit(json_encode([ - 'code' => 1007, - 'msg' => '不支持的图片格式' - ])); - } - - // 创建新图像 - $thumb = imagecreatetruecolor($newWidth, $newHeight); - - // 保持PNG和WebP的透明度 - if ($imageInfo[2] == IMAGETYPE_PNG || $imageInfo[2] == IMAGETYPE_WEBP) { - imagealphablending($thumb, false); - imagesavealpha($thumb, true); - $transparent = imagecolorallocatealpha($thumb, 255, 255, 255, 127); - imagefilledrectangle($thumb, 0, 0, $newWidth, $newHeight, $transparent); - } - - // 调整图像大小 - imagecopyresampled($thumb, $source, 0, 0, 0, 0, $newWidth, $newHeight, $width, $height); - - // 保存图像 - switch ($imageInfo[2]) { - case IMAGETYPE_JPEG: - $uploaded = imagejpeg($thumb, $uploadPath, 90); - break; - case IMAGETYPE_PNG: - $uploaded = imagepng($thumb, $uploadPath, 9); - break; - case IMAGETYPE_GIF: - $uploaded = imagegif($thumb, $uploadPath); - break; - case IMAGETYPE_WEBP: - $uploaded = imagewebp($thumb, $uploadPath, 90); - break; - } - - // 释放内存 - imagedestroy($source); - imagedestroy($thumb); -} else { - // 直接移动上传的文件 - $uploaded = move_uploaded_file($_FILES['image']['tmp_name'], $uploadPath); -} - -// 检查上传是否成功 -if (!$uploaded) { - exit(json_encode([ - 'code' => 1008, - 'msg' => '文件保存失败' - ])); -} - -// 记录日志 -$user = $_SESSION['user']; -$ip = "".$_SERVER['REMOTE_ADDR']; -$db = new DB(); -$db->insert('logs', [ - 'user_id' => $user['id'], - 'action' => '上传图片', - 'idesc' => '上传了图片: ' . $fileName, - 'ip' => $ip, - 'logtime' => date('Y-m-d H:i:s') -]); - -// 返回成功信息和图片URL -exit(json_encode([ - 'code' => 0, - 'msg' => '上传成功', - 'data' => [ - 'url' => $relativeUrl, - 'width' => $width, - 'height' => $height - ] -])); - -/** - * 获取上传错误消息 - * @param int $errorCode 上传错误代码 - * @return string 错误消息 - */ -function uploadErrorMessage($errorCode) { - switch ($errorCode) { - case UPLOAD_ERR_INI_SIZE: - return '上传的文件超过了php.ini中upload_max_filesize指令限制的大小'; - case UPLOAD_ERR_FORM_SIZE: - return '上传的文件超过了HTML表单中MAX_FILE_SIZE指令指定的大小'; - case UPLOAD_ERR_PARTIAL: - return '文件只有部分被上传'; - case UPLOAD_ERR_NO_FILE: - return '没有文件被上传'; - case UPLOAD_ERR_NO_TMP_DIR: - return '找不到临时文件夹'; - case UPLOAD_ERR_CANT_WRITE: - return '文件写入失败'; - case UPLOAD_ERR_EXTENSION: - return '文件上传被PHP扩展程序中断'; - default: - return '未知上传错误'; - } -} diff --git a/ht/api/user.php b/ht/api/user.php deleted file mode 100644 index fb42fe0..0000000 --- a/ht/api/user.php +++ /dev/null @@ -1,238 +0,0 @@ -getOne('users', "username = '$username'"); - - // 验证用户和密码 - if (!$user || !password_verify($password, $user['password'])) { - ajaxReturn(1, '用户名或密码错误'); - } - - // 验证用户状态 - if ($user['status'] != 1) { - ajaxReturn(1, '账号已被禁用,请联系管理员'); - } - - // 更新最后登录时间 - $db->update('users', [ - 'logtime' => date('Y-m-d H:i:s') - ], "id = {$user['id']}"); - - // 记录登录日志 - writeLog($user['id'], 'login', '用户登录'); - - // 存储session - session_start(); - $_SESSION['user'] = $user; - - ajaxReturn(0, '登录成功', $user); - break; - - // 用户注册 - case 'register': - // 获取参数 - $username = isset($_POST['username']) ? safeFilter($_POST['username']) : ''; - $password = isset($_POST['password']) ? $_POST['password'] : ''; - $userIdentifier = isset($_POST['user_identifier']) ? safeFilter($_POST['user_identifier']) : ''; - - // 参数验证 - if (empty($username) || empty($password)) { - ajaxReturn(1, '账号和密码不能为空'); - } - - // 验证账号格式(手机号/邮箱/微信号) - $phoneRegex = '/^1[3456789]\d{9}$/'; - $emailRegex = '/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/'; - $wechatRegex = '/^[a-zA-Z0-9_-]{6,20}$/'; - - if (!preg_match($phoneRegex, $username) && !preg_match($emailRegex, $username) && !preg_match($wechatRegex, $username)) { - ajaxReturn(1, '请输入正确的手机号、邮箱或微信号'); - } - - // 验证密码长度 - if (strlen($password) < 6) { - ajaxReturn(1, '密码长度不能少于6位'); - } - - // 检查用户名是否已存在 - $existUser = $db->getOne('users', "username = '$username'"); - if ($existUser) { - ajaxReturn(1, '该账号已被注册'); - } - - // 密码加密 - $hashedPassword = password_hash($password, PASSWORD_DEFAULT); - - // 添加用户 - $userId = $db->insert('users', [ - 'username' => $username, - 'password' => $hashedPassword, - 'irole' => 0, // 普通用户 - 'status' => 1, // 正常状态 - 'regtime' => date('Y-m-d H:i:s'), - 'user_identifier' => $userIdentifier - ]); - - if (!$userId) { - ajaxReturn(1, '注册失败,请稍后重试'); - } - - // 记录注册日志 - writeLog($userId, 'register', '用户注册'); - - ajaxReturn(0, '注册成功'); - break; - - // 用户登出 - case 'logout': - session_start(); - - // 记录登出日志 - if (isset($_SESSION['user']) && !empty($_SESSION['user']['id'])) { - writeLog($_SESSION['user']['id'], 'logout', '用户登出'); - } - - // 清除session - unset($_SESSION['user']); - session_destroy(); - - // 跳转到首页 - header('Location: ../index.php'); - exit; - break; - - // 获取用户信息 - case 'getUserInfo': - // 验证权限 - $user = checkAuth('getUserInfo'); - if (!$user) { - exit; - } - - // 移除敏感信息 - unset($user['password']); - - ajaxReturn(0, '获取成功', $user); - break; - - // 更新用户信息 - case 'updateUserInfo': - // 验证权限 - $user = checkAuth('updateUserInfo'); - if (!$user) { - exit; - } - - // 获取参数 - $newPassword = isset($_POST['new_password']) ? $_POST['new_password'] : ''; - $confirmPassword = isset($_POST['confirm_password']) ? $_POST['confirm_password'] : ''; - - // 如果要更新密码 - if (!empty($newPassword)) { - // 验证密码长度 - if (strlen($newPassword) < 6) { - ajaxReturn(1, '密码长度不能少于6位'); - } - - // 验证两次密码是否一致 - if ($newPassword !== $confirmPassword) { - ajaxReturn(1, '两次输入的密码不一致'); - } - - // 更新密码 - $hashedPassword = password_hash($newPassword, PASSWORD_DEFAULT); - - // 更新用户信息 - $result = $db->update('users', [ - 'password' => $hashedPassword - ], "id = {$user['id']}"); - - if (!$result) { - ajaxReturn(1, '更新失败,请稍后重试'); - } - - // 记录日志 - writeLog($user['id'], 'update_password', '修改密码'); - - // 更新 session 中的用户信息 - $updatedUser = $db->getOne('users', "id = {$user['id']}"); - $_SESSION['user'] = $updatedUser; - - ajaxReturn(0, '密码更新成功'); - } else { - ajaxReturn(1, '请输入新密码'); - } - break; - - // 更新用户标识 - case 'updateUserIdentifier': - // 验证权限 - $user = checkAuth('updateUserIdentifier'); - if (!$user) { - exit; - } - - // 获取参数 - $userIdentifier = isset($_POST['user_identifier']) ? safeFilter($_POST['user_identifier']) : ''; - - // 验证用户标识长度 - if (strlen($userIdentifier) > 100) { - ajaxReturn(1, '用户标识长度不能超过100个字符'); - } - - // 更新用户标识 - $result = $db->update('users', [ - 'user_identifier' => $userIdentifier - ], "id = {$user['id']}"); - - if (!$result) { - ajaxReturn(1, '更新失败,请稍后重试'); - } - - // 记录日志 - writeLog($user['id'], 'update_identifier', '更新用户标识'); - - // 获取更新后的用户信息 - $updatedUser = $db->getOne('users', "id = {$user['id']}"); - - // 移除敏感信息 - unset($updatedUser['password']); - - // 更新 session 中的用户信息 - $_SESSION['user'] = $updatedUser; - - ajaxReturn(0, '更新成功', $updatedUser); - break; - - // 未知操作 - default: - ajaxReturn(1, '未知操作'); - break; -} diff --git a/ht/api/vote.php b/ht/api/vote.php deleted file mode 100644 index 5ee2849..0000000 --- a/ht/api/vote.php +++ /dev/null @@ -1,219 +0,0 @@ -getOne('vote', "id = $topicId"); - if (!$vote) { - ajaxReturn(1, '投票不存在'); - } - - // 验证投票状态 - $now = date('Y-m-d H:i:s'); - if ($vote['status'] != 1) { - ajaxReturn(1, '该投票已被禁用'); - } - - if ($vote['statime'] > $now) { - ajaxReturn(1, '该投票尚未开始'); - } - - if ($vote['endtime'] < $now) { - ajaxReturn(1, '该投票已经结束'); - } - - // 检查用户是否已投票 - $hasVoted = $db->count('recs', "topic_id = $topicId AND user_id = {$user['id']}"); - if ($hasVoted > 0) { - ajaxReturn(1, '您已经参与过该投票'); - } - - // 验证选项数量 - if ($vote['itype'] == 1 && count($options) > $vote['maxtime']) { - ajaxReturn(1, "最多只能选择 {$vote['maxtime']} 项"); - } - - // 验证选项是否存在 - foreach ($options as $optionId) { - $option = $db->getOne('xuan', "id = $optionId AND topic_id = $topicId"); - if (!$option) { - ajaxReturn(1, '选项不存在'); - } - } - - // 开始事务 - $db->startTransaction(); - - try { - // 添加投票记录 - $ip = $_SERVER['REMOTE_ADDR']; - $time = date('Y-m-d H:i:s'); - - foreach ($options as $optionId) { - $result = $db->insert('recs', [ - 'topic_id' => $topicId, - 'user_id' => $user['id'], - 'option_id' => $optionId, - 'vote_time' => $time, - 'ip' => $ip - ]); - - if (!$result) { - throw new Exception('提交投票失败'); - } - } - - // 记录日志 - writeLog($user['id'], 'vote', "参与投票:{$vote['title']}"); - - // 提交事务 - $db->commit(); - - ajaxReturn(0, '投票成功'); - } catch (Exception $e) { - // 回滚事务 - $db->rollback(); - ajaxReturn(1, $e->getMessage()); - } - break; - - // 检查是否已投票 - case 'checkVoted': - // 验证权限 - $user = checkAuth('checkVoted'); - if (!$user) { - exit; - } - - // 获取参数 - $topicId = isset($_REQUEST['topic_id']) ? intval($_REQUEST['topic_id']) : 0; - - // 参数验证 - if (empty($topicId)) { - ajaxReturn(1, '参数错误'); - } - - // 检查用户是否已投票 - $hasVoted = $db->count('recs', "topic_id = $topicId AND user_id = {$user['id']}"); - - ajaxReturn(0, '查询成功', ['hasVoted' => $hasVoted > 0]); - break; - - // 获取投票结果 - case 'getResult': - // 获取参数 - $topicId = isset($_REQUEST['topic_id']) ? intval($_REQUEST['topic_id']) : 0; - - // 参数验证 - if (empty($topicId)) { - ajaxReturn(1, '参数错误'); - } - - // 获取投票信息 - $vote = $db->getOne('vote', "id = $topicId"); - if (!$vote) { - ajaxReturn(1, '投票不存在'); - } - - // 获取选项列表 - $options = $db->getAll('xuan', "topic_id = $topicId", '*', 'sort ASC, id ASC'); - if (empty($options)) { - ajaxReturn(1, '暂无投票选项'); - } - - // 获取投票结果 - $sql = "SELECT option_id, COUNT(*) as vote_count FROM " . $db->table('recs') . " WHERE topic_id = $topicId GROUP BY option_id"; - $result = $db->query($sql); - - $voteResults = []; - $totalVotes = 0; - - if ($result) { - while ($row = $result->fetch_assoc()) { - $voteResults[$row['option_id']] = $row['vote_count']; - $totalVotes += $row['vote_count']; - } - } - - // 格式化结果 - $formattedResults = []; - foreach ($options as $option) { - $voteCount = isset($voteResults[$option['id']]) ? $voteResults[$option['id']] : 0; - $percentage = $totalVotes > 0 ? round(($voteCount / $totalVotes) * 100, 1) : 0; - - $formattedResults[] = [ - 'id' => $option['id'], - 'name' => $option['name'], - 'count' => $voteCount, - 'percentage' => $percentage - ]; - } - - // 用户是否已投票 - $hasVoted = false; - $userVotes = []; - - if (isset($_SESSION['user']) && !empty($_SESSION['user']['id'])) { - $userId = $_SESSION['user']['id']; - $userVoteRecords = $db->getAll('recs', "topic_id = $topicId AND user_id = $userId"); - - if (!empty($userVoteRecords)) { - $hasVoted = true; - foreach ($userVoteRecords as $record) { - $userVotes[] = $record['option_id']; - } - } - } - - ajaxReturn(0, '获取成功', [ - 'vote' => $vote, - 'options' => $options, - 'results' => $formattedResults, - 'totalVotes' => $totalVotes, - 'hasVoted' => $hasVoted, - 'userVotes' => $userVotes - ]); - break; - - // 未知操作 - default: - ajaxReturn(1, '未知操作'); - break; -} diff --git a/ht/docs/superpowers/specs/2026-03-27-poetry-quiz-frontend-design.md b/ht/docs/superpowers/specs/2026-03-27-poetry-quiz-frontend-design.md deleted file mode 100644 index d17ee2a..0000000 --- a/ht/docs/superpowers/specs/2026-03-27-poetry-quiz-frontend-design.md +++ /dev/null @@ -1,111 +0,0 @@ -# 古诗文答题系统前端设计文档 - -## 概述 -为 `p1/api.php` API 创建一个古风风格的前端答题页面,包含题目获取、答案提交、提示功能和答题统计。 - -## 设计决策 - -### 布局风格 -- **选择**: 单卡片居中布局 -- **原因**: 答题系统一次只显示一道题,居中卡片布局更专注 - -### 配色方案 -- **选择**: 古风配色 -- **原因**: 符合古诗文主题,营造文化氛围 - -### 功能模块 -- 答题统计(答对/总题数) -- 题目导航(数字按钮) -- 题目详情(作者、朝代、年级、类型) - -## 页面架构 - -``` -┌─────────────────────────────────────────────┐ -│ 页面头部 │ -│ 📜 古诗文答题 · 统计信息 │ -├─────────────────────────────────────────────┤ -│ ┌─────────────────┐ │ -│ │ 题目导航条 │ │ -│ │ 1 2 3 4 5 ... │ │ -│ └─────────────────┘ │ -│ │ -│ ┌─────────────────┐ │ -│ │ 题目卡片 │ │ -│ │ (宣纸质感) │ │ -│ │ [选项按钮] │ │ -│ │ 💡 提示按钮 │ │ -│ └─────────────────┘ │ -│ │ -│ ┌─────────────────┐ │ -│ │ 题目详情 │ │ -│ │ 作者·朝代·年级 │ │ -│ └─────────────────┘ │ -└─────────────────────────────────────────────┘ -``` - -## 配色方案 - -```css ---bg-primary: #f5f0e6; /* 米色背景 */ ---bg-card: #fffef9; /* 宣纸白 */ ---text-primary: #5d4e37; /* 棕色文字 */ ---text-secondary: #8b7355; /* 浅棕色 */ ---accent: #c94c4c; /* 朱红色(印章色) */ ---border: #d4c5a9; /* 边框色 */ ---success: #4a7c59; /* 正确提示绿 */ ---error: #c94c4c; /* 错误提示红 */ -``` - -## 视觉元素 - -- 卡片圆角: 12px -- 选项按钮: 印章风格,方形圆角,悬停时微微放大 -- 动画: 平滑过渡 0.3s -- 字体: 题目使用「楷体」,选项使用「微软雅黑」 - -## 交互流程 - -1. 页面初始化 → 从 URL 获取 id 参数(默认 id=1) -2. 调用 API 获取题目 → 显示题目卡片 -3. 用户选择选项 → 提交答案 -4. API 返回结果 → 显示反馈 - - 正确: 显示成功动画,自动加载下一题 - - 错误: 显示错误提示,可点击「提示」按钮 - - 提示: 显示提示信息 - -## API 调用 - -```javascript -// 获取题目 -GET api.php?id=1 - -// 提交答案 -GET api.php?id=1&msg=1 - -// 获取提示 -GET api.php?id=1&msg=提示 -``` - -## 状态管理 - -- `currentId`: 当前题目 ID -- `correctCount`: 答对题数 -- `totalCount`: 总答题数 -- `selectedOption`: 当前选中选项 - -## 文件结构 - -``` -p1/ -├── index.html # 页面结构 -├── api.js # API 调用与交互逻辑 -├── api.php # 后端 API -└── API文档.md # API 文档 -``` - -## 错误处理 - -- 网络错误: 显示友好提示,提供重试按钮 -- API 错误: 显示错误信息 -- 题目不存在: 提示用户 diff --git a/ht/inc/conn.php b/ht/inc/conn.php deleted file mode 100644 index b593be8..0000000 --- a/ht/inc/conn.php +++ /dev/null @@ -1,78 +0,0 @@ - '简约投票简洁投票系统', - - // 数据库配置 - 'db' => [ - 'host' => 'localhost', - 'user' => 'toupiao', - 'pass' => 'toupiao', - 'name' => 'toupiao', - 'port' => 3306, - 'prefix' => 'tp_', - 'charset' => 'utf8' - ], - - // 资源文件缓存控制(修改版本号可更新前端缓存) - 'version' => [ - 'css' => '1.0.0', - 'js' => '1.0.0' - ] -]; - -// 数据库连接 -function dbConnect() { - global $CONFIG; - - $conn = new mysqli( - $CONFIG['db']['host'], - $CONFIG['db']['user'], - $CONFIG['db']['pass'], - $CONFIG['db']['name'], - $CONFIG['db']['port'] - ); - - // 检查连接 - if ($conn->connect_error) { - die("数据库连接失败: " . $conn->connect_error); - } - - // 设置字符集 - $conn->set_charset($CONFIG['db']['charset']); - - return $conn; -} - -// 数据表前缀函数 -function getTable($table) { - global $CONFIG; - return $CONFIG['db']['prefix'] . $table; -} - -// 获取带版本号的CSS路径 -function getCssPath($file) { - global $CONFIG; - return "/assets/css/{$file}?v=" . $CONFIG['version']['css']; -} - -// 获取带版本号的JS路径 -function getJsPath($file) { - global $CONFIG; - return "/assets/js/{$file}?v=" . $CONFIG['version']['js']; -} - -// 获取网站标题 -function getSiteTitle() { - global $CONFIG; - return $CONFIG['site_title']; -} diff --git a/ht/inc/css.css b/ht/inc/css.css deleted file mode 100644 index d29e6ed..0000000 --- a/ht/inc/css.css +++ /dev/null @@ -1,495 +0,0 @@ -/** - * 公共CSS样式 - */ - -/* 全局重置 */ -* { - margin: 0; - padding: 0; - box-sizing: border-box; -} - -body { - font-family: 'Microsoft YaHei', Arial, sans-serif; - font-size: 14px; - line-height: 1.5; - color: #333; - background-color: #f5f5f5; -} - -/* 顶部菜单样式 */ -.header { - background-color: #2c3e50; - color: #fff; - position: fixed; - width: 100%; - top: 0; - left: 0; - z-index: 100; - box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); -} - -.header-container { - display: flex; - justify-content: space-between; - align-items: center; - max-width: 1200px; - margin: 0 auto; - padding: 0 15px; - height: 60px; -} - -.logo { - font-size: 20px; - font-weight: bold; -} - -.nav { - display: flex; -} - -.nav-item { - margin-left: 20px; - color: #fff; - text-decoration: none; - transition: color 0.3s; -} - -.nav-item:hover { - color: #3498db; -} - -.active { - color: #3498db; -} - -/* 主体内容 */ -.main { - max-width: 1200px; - margin: 80px auto 20px; - padding: 20px; - background-color: #fff; - border-radius: 5px; - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); -} - -/* 遮罩层样式 */ -.mask-container { - position: fixed; - top: 0; - left: 0; - width: 100%; - height: 100%; - background-color: rgba(0, 0, 0, 0.5); - display: flex; - justify-content: center; - align-items: center; - z-index: 1000; -} - -.mask-dialog { - position: relative; - background-color: #fff; - border-radius: 5px; - box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); - width: 80%; - max-width: 600px; - display: flex; - flex-direction: column; - max-height: 90vh; -} - -.mask-title { - display: flex; - justify-content: space-between; - align-items: center; - padding: 15px 20px; - border-bottom: 1px solid #eee; -} - -.mask-title h3 { - margin: 0; - font-size: 18px; -} - -.mask-close { - font-size: 24px; - cursor: pointer; - color: #999; - transition: color 0.3s; -} - -.mask-close:hover { - color: #333; -} - -.mask-content { - padding: 20px; - overflow-y: auto; - flex: 1; -} - -.mask-buttons { - padding: 15px 20px; - border-top: 1px solid #eee; - display: flex; - justify-content: flex-end; - position: sticky; - bottom: 0; - background-color: #fff; - border-radius: 0 0 5px 5px; -} - -.mask-button { - padding: 8px 15px; - margin-left: 10px; - border: none; - border-radius: 3px; - cursor: pointer; - transition: background-color 0.3s; -} - -.btn-primary { - background-color: #3498db; - color: #fff; -} - -.btn-primary:hover { - background-color: #2980b9; -} - -.btn-default { - background-color: #f5f5f5; - color: #333; -} - -.btn-default:hover { - background-color: #e0e0e0; -} - -.btn-danger { - background-color: #e74c3c; - color: #fff; -} - -.btn-danger:hover { - background-color: #c0392b; -} - -/* 表格通用样式 */ -.table-container { - width: 100%; - overflow-x: auto; - margin-bottom: 20px; -} - -table { - width: 100%; - border-collapse: collapse; - border: 1px solid #ddd; -} - -th, td { - padding: 12px 15px; - text-align: left; - border-bottom: 1px solid #ddd; -} - -th { - background-color: #f8f8f8; - font-weight: bold; - cursor: pointer; - position: relative; -} - -th.sort-asc::after { - content: '↑'; - margin-left: 5px; -} - -th.sort-desc::after { - content: '↓'; - margin-left: 5px; -} - -tr:hover { - background-color: #f5f5f5; -} - -/* 表单通用样式 */ -.form-container { - max-width: 600px; - margin: 0 auto; -} - -.form-group { - margin-bottom: 15px; -} - -.form-label { - display: block; - margin-bottom: 5px; - font-weight: bold; -} - -.form-control { - width: 100%; - padding: 10px; - border: 1px solid #ddd; - border-radius: 3px; - font-size: 14px; - transition: border-color 0.3s; -} - -.form-control:focus { - border-color: #3498db; - outline: none; -} - -.form-error { - color: #e74c3c; - font-size: 12px; - margin-top: 5px; -} - -.form-submit { - background-color: #3498db; - color: #fff; - border: none; - padding: 10px 15px; - border-radius: 3px; - cursor: pointer; - transition: background-color 0.3s; -} - -.form-submit:hover { - background-color: #2980b9; -} - -/* 分页样式 */ -.pagination { - display: flex; - align-items: center; - justify-content: center; - margin: 20px 0; -} - -.pagination.disabled { - display: none; -} - -.page-item { - padding: 8px 12px; - margin: 0 3px; - border: 1px solid #ddd; - border-radius: 3px; - color: #333; - text-decoration: none; - transition: background-color 0.3s; -} - -.page-item:hover:not(.disabled) { - background-color: #f5f5f5; -} - -.page-item.disabled { - color: #ccc; - cursor: not-allowed; - background-color: #f5f5f5; -} - -.page-select { - margin: 0 10px; - padding: 8px; - border: 1px solid #ddd; - border-radius: 3px; -} - -/* 提示框样式 */ -.suggest-container { - position: absolute; - background-color: #fff; - border: 1px solid #ddd; - border-top: none; - border-radius: 0 0 3px 3px; - box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1); - z-index: 100; - max-height: 300px; - overflow-y: auto; -} - -.suggest-item { - padding: 10px; - cursor: pointer; - transition: background-color 0.3s; -} - -.suggest-item:hover { - background-color: #f5f5f5; -} - -.suggest-close { - padding: 10px; - text-align: right; - color: #999; - cursor: pointer; - border-bottom: 1px solid #eee; -} - -/* 按钮通用样式 */ -.btn { - display: inline-block; - padding: 8px 15px; - border: none; - border-radius: 3px; - cursor: pointer; - text-decoration: none; - transition: background-color 0.3s; - margin-right: 5px; -} - -.btn-sm { - padding: 5px 10px; - font-size: 12px; -} - -.btn-lg { - padding: 12px 20px; - font-size: 16px; -} - -.btn-blue { - background-color: #3498db; - color: #fff; -} - -.btn-blue:hover { - background-color: #2980b9; -} - -.btn-green { - background-color: #2ecc71; - color: #fff; -} - -.btn-green:hover { - background-color: #27ae60; -} - -.btn-red { - background-color: #e74c3c; - color: #fff; -} - -.btn-red:hover { - background-color: #c0392b; -} - -.btn-gray { - background-color: #95a5a6; - color: #fff; -} - -.btn-gray:hover { - background-color: #7f8c8d; -} - -/* 卡片样式 */ -.card { - background-color: #fff; - border-radius: 5px; - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); - margin-bottom: 20px; - overflow: hidden; -} - -.card-header { - padding: 15px; - border-bottom: 1px solid #eee; - background-color: #f8f8f8; -} - -.card-title { - margin: 0; - font-size: 18px; -} - -.card-body { - padding: 15px; -} - -.card-footer { - padding: 15px; - border-top: 1px solid #eee; - background-color: #f8f8f8; -} - -/* 投票选项样式 */ -.vote-option { - border: 1px solid #ddd; - border-radius: 3px; - padding: 15px; - margin-bottom: 10px; - transition: all 0.3s; - cursor: pointer; -} - -.vote-option:hover { - border-color: #3498db; - box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); -} - -.vote-option.selected { - border-color: #3498db; - background-color: #ebf5fb; -} - -.vote-option-img { - max-width: 100%; - height: auto; - margin-bottom: 10px; -} - -.vote-result { - margin-top: 5px; -} - -.vote-bar { - height: 20px; - background-color: #eee; - border-radius: 10px; - overflow: hidden; - margin-top: 5px; -} - -.vote-bar-fill { - height: 100%; - background-color: #3498db; - border-radius: 10px; -} - -/* 响应式调整 */ -@media (max-width: 768px) { - .header-container { - height: auto; - padding: 10px 15px; - flex-direction: column; - } - - .nav { - margin-top: 10px; - } - - .main { - margin-top: 120px; - padding: 15px; - } - - .mask-dialog { - width: 95%; - } - - .form-container { - padding: 0 10px; - } -} diff --git a/ht/inc/js.js b/ht/inc/js.js deleted file mode 100644 index dba1802..0000000 --- a/ht/inc/js.js +++ /dev/null @@ -1,458 +0,0 @@ -/** - * 公共JavaScript函数 - */ - -/** - * Ajax通信函数 - * @param {string} url - 请求地址 - * @param {Object} data - 请求数据 - * @param {Function} callback - 成功回调函数 - * @param {Function} errorCallback - 错误回调函数 - * @param {string} method - 请求方法(GET或POST) - */ -function ajaxRequest(url, data, callback, errorCallback, method) { - // 默认使用POST方法,除非act为get - if (!method) { - method = (data && data.act === 'get') ? 'GET' : 'POST'; - } - - // 创建XMLHttpRequest对象 - var xhr = new XMLHttpRequest(); - - // 准备发送请求 - xhr.open(method, url, true); - - // 设置请求头 - xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest'); - - if (method === 'POST') { - xhr.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded'); - } - - // 处理响应 - xhr.onreadystatechange = function() { - if (xhr.readyState === 4) { - if (xhr.status === 200) { - var response; - try { - response = JSON.parse(xhr.responseText); - if (callback && typeof callback === 'function') { - callback(response); - } - } catch (e) { - console.error('解析JSON失败:', e); - if (errorCallback && typeof errorCallback === 'function') { - errorCallback('解析响应失败'); - } - } - } else { - console.error('请求失败,状态码:', xhr.status); - if (errorCallback && typeof errorCallback === 'function') { - errorCallback('请求失败,状态码: ' + xhr.status); - } - } - } - }; - - // 处理请求超时 - xhr.ontimeout = function() { - console.error('请求超时'); - if (errorCallback && typeof errorCallback === 'function') { - errorCallback('请求超时'); - } - }; - - // 处理网络错误 - xhr.onerror = function() { - console.error('网络错误'); - if (errorCallback && typeof errorCallback === 'function') { - errorCallback('网络错误'); - } - }; - - // 发送请求 - if (method === 'POST' && data) { - // 将对象转换为查询字符串 - var params = Object.keys(data).map(function(key) { - return encodeURIComponent(key) + '=' + encodeURIComponent(data[key]); - }).join('&'); - xhr.send(params); - } else if (method === 'GET' && data) { - // 将查询参数添加到URL - var queryString = Object.keys(data).map(function(key) { - return encodeURIComponent(key) + '=' + encodeURIComponent(data[key]); - }).join('&'); - - var separator = url.indexOf('?') !== -1 ? '&' : '?'; - xhr.send(); - } else { - xhr.send(); - } -} - -/** - * 分页显示函数 - * @param {string} containerId - 分页容器ID - * @param {number} currentPage - 当前页码 - * @param {number} totalPages - 总页数 - * @param {Function} callback - 页码点击回调函数 - */ -function pagination(containerId, currentPage, totalPages, callback) { - var container = document.getElementById(containerId); - if (!container) return; - - // 清空容器 - container.innerHTML = ''; - - // 如果没有数据或只有一页,不显示分页 - if (totalPages <= 1) { - container.classList.add('disabled'); - return; - } - - container.classList.remove('disabled'); - - // 创建分页元素 - var paginationHtml = ''; - - // 首页按钮 - var firstDisabled = currentPage === 1 ? ' disabled' : ''; - paginationHtml += '首页'; - - // 上一页按钮 - var prevDisabled = currentPage === 1 ? ' disabled' : ''; - var prevPage = Math.max(1, currentPage - 1); - paginationHtml += '上一页'; - - // 页码下拉选择 - paginationHtml += ''; - - // 下一页按钮 - var nextDisabled = currentPage === totalPages ? ' disabled' : ''; - var nextPage = Math.min(totalPages, currentPage + 1); - paginationHtml += '下一页'; - - // 尾页按钮 - var lastDisabled = currentPage === totalPages ? ' disabled' : ''; - paginationHtml += '尾页'; - - // 设置HTML - container.innerHTML = paginationHtml; - - // 绑定事件 - // 点击页码按钮 - var pageItems = container.querySelectorAll('.page-item'); - for (var j = 0; j < pageItems.length; j++) { - var item = pageItems[j]; - if (!item.classList.contains('disabled')) { - item.addEventListener('click', function() { - var page = parseInt(this.getAttribute('data-page')); - if (callback && typeof callback === 'function') { - callback(page); - } - }); - } - } - - // 下拉选择页码 - var pageSelect = container.querySelector('.page-select'); - if (pageSelect) { - pageSelect.addEventListener('change', function() { - var page = parseInt(this.value); - if (callback && typeof callback === 'function') { - callback(page); - } - }); - } -} - -/** - * 表格排序函数 - * @param {string} tableId - 表格ID - * @param {number} colIndex - 排序列索引 - * @param {string} type - 排序类型(string, number, date) - */ -function sortTable(tableId, colIndex, type) { - var table = document.getElementById(tableId); - if (!table) return; - - var tbody = table.getElementsByTagName('tbody')[0]; - var rows = tbody.getElementsByTagName('tr'); - var sortedRows = Array.prototype.slice.call(rows, 0); - - // 确定排序方向 - var sortDirection = 1; // 1为升序,-1为降序 - if (table.getAttribute('data-sort-col') == colIndex) { - sortDirection = table.getAttribute('data-sort-dir') == 'asc' ? -1 : 1; - } - - // 保存排序信息 - table.setAttribute('data-sort-col', colIndex); - table.setAttribute('data-sort-dir', sortDirection == 1 ? 'asc' : 'desc'); - - // 排序 - sortedRows.sort(function(a, b) { - var cellA = a.cells[colIndex].textContent.trim(); - var cellB = b.cells[colIndex].textContent.trim(); - - if (type === 'number') { - return sortDirection * (parseFloat(cellA) - parseFloat(cellB)); - } else if (type === 'date') { - var dateA = new Date(cellA); - var dateB = new Date(cellB); - return sortDirection * (dateA - dateB); - } else { - return sortDirection * cellA.localeCompare(cellB); - } - }); - - // 更新表格显示 - for (var i = 0; i < sortedRows.length; i++) { - tbody.appendChild(sortedRows[i]); - } - - // 更新表格头部排序指示器 - var headers = table.getElementsByTagName('th'); - for (var j = 0; j < headers.length; j++) { - headers[j].classList.remove('sort-asc', 'sort-desc'); - } - - if (headers[colIndex]) { - headers[colIndex].classList.add(sortDirection == 1 ? 'sort-asc' : 'sort-desc'); - } -} - -/** - * 显示遮罩层 - * @param {string} title - 标题 - * @param {string} content - 内容 - * @param {Array} buttons - 按钮配置数组,格式:[{text: '按钮文字', callback: 回调函数, class: 'btn-class'}] - */ -function showMask(title, content, buttons) { - // 移除已存在的遮罩 - closeMask(); - - // 创建遮罩层 - var mask = document.createElement('div'); - mask.className = 'mask-container'; - - // 创建对话框 - var dialog = document.createElement('div'); - dialog.className = 'mask-dialog'; - - // 创建标题栏 - var titleBar = document.createElement('div'); - titleBar.className = 'mask-title'; - titleBar.innerHTML = '

' + title + '

×'; - - // 创建内容区 - var contentArea = document.createElement('div'); - contentArea.className = 'mask-content'; - contentArea.innerHTML = content; - - // 创建按钮区 - var buttonArea = document.createElement('div'); - buttonArea.className = 'mask-buttons'; - - if (buttons && buttons.length > 0) { - buttons.forEach(function(btn) { - var button = document.createElement('button'); - button.className = 'mask-button ' + (btn.class || ''); - button.textContent = btn.text; - - if (btn.callback && typeof btn.callback === 'function') { - button.addEventListener('click', function() { - btn.callback(); - }); - } - - buttonArea.appendChild(button); - }); - } - - // 组装对话框 - dialog.appendChild(titleBar); - dialog.appendChild(contentArea); - dialog.appendChild(buttonArea); - mask.appendChild(dialog); - - // 添加到页面 - document.body.appendChild(mask); - - // 绑定关闭事件 - var closeBtn = mask.querySelector('.mask-close'); - if (closeBtn) { - closeBtn.addEventListener('click', closeMask); - } - - // 绑定点击遮罩层关闭 - mask.addEventListener('click', function(e) { - if (e.target === mask) { - closeMask(); - } - }); - - // 禁止页面滚动 - document.body.style.overflow = 'hidden'; - - // 调整内容区域最大高度 - var contentMaxHeight = window.innerHeight * 0.7; - contentArea.style.maxHeight = contentMaxHeight + 'px'; -} - -/** - * 关闭遮罩层 - */ -function closeMask() { - var mask = document.querySelector('.mask-container'); - if (mask) { - mask.parentNode.removeChild(mask); - } - - // 恢复页面滚动 - document.body.style.overflow = ''; -} - -/** - * 输入提示功能 - * @param {string} inputId - 输入框ID - * @param {string} url - 获取提示数据的URL - * @param {Object} params - 附加参数 - * @param {Function} callback - 选择项后的回调函数 - */ -function searchSuggest(inputId, url, params, callback) { - var input = document.getElementById(inputId); - if (!input) return; - - // 创建提示容器 - var suggestContainer = document.createElement('div'); - suggestContainer.className = 'suggest-container'; - suggestContainer.style.display = 'none'; - input.parentNode.appendChild(suggestContainer); - - // 定位提示容器 - function positionSuggest() { - var rect = input.getBoundingClientRect(); - suggestContainer.style.top = (rect.bottom + window.scrollY) + 'px'; - suggestContainer.style.left = (rect.left + window.scrollX) + 'px'; - suggestContainer.style.width = rect.width + 'px'; - } - - // 暂存上一次请求的关键词 - var lastKeyword = ''; - var debounceTimer = null; - - // 处理输入事件 - input.addEventListener('input', function() { - var keyword = input.value.trim(); - - // 清除上一次的定时器 - if (debounceTimer) { - clearTimeout(debounceTimer); - } - - // 如果关键词为空,隐藏提示 - if (!keyword) { - suggestContainer.style.display = 'none'; - return; - } - - // 如果关键词与上一次相同,不重新请求 - if (keyword === lastKeyword) { - return; - } - - // 设置300ms的防抖定时器 - debounceTimer = setTimeout(function() { - lastKeyword = keyword; - - // 准备请求参数 - var requestParams = Object.assign({}, params || {}, { - keyword: keyword - }); - - // 发送请求获取提示数据 - ajaxRequest(url, requestParams, function(response) { - if (response.code === 0 && Array.isArray(response.data) && response.data.length > 0) { - // 清空容器 - suggestContainer.innerHTML = ''; - - // 添加关闭按钮 - var closeButton = document.createElement('div'); - closeButton.className = 'suggest-close'; - closeButton.textContent = '关闭'; - closeButton.addEventListener('click', function() { - suggestContainer.style.display = 'none'; - }); - suggestContainer.appendChild(closeButton); - - // 限制最多显示10条 - var maxItems = Math.min(10, response.data.length); - - // 添加提示项 - for (var i = 0; i < maxItems; i++) { - var item = response.data[i]; - var suggestionItem = document.createElement('div'); - suggestionItem.className = 'suggest-item'; - suggestionItem.textContent = item.text || item.name || item; - suggestionItem.setAttribute('data-value', item.value || item.id || item); - - // 绑定点击事件 - suggestionItem.addEventListener('click', function() { - var value = this.getAttribute('data-value'); - var text = this.textContent; - - // 设置输入框值 - input.value = text; - - // 隐藏提示 - suggestContainer.style.display = 'none'; - - // 触发回调 - if (callback && typeof callback === 'function') { - callback(value, text); - } - }); - - suggestContainer.appendChild(suggestionItem); - } - - // 显示提示容器 - positionSuggest(); - suggestContainer.style.display = 'block'; - } else { - suggestContainer.style.display = 'none'; - } - }, function() { - suggestContainer.style.display = 'none'; - }); - }, 300); - }); - - // 点击输入框时,如果有数据则显示提示 - input.addEventListener('click', function() { - if (lastKeyword && suggestContainer.childElementCount > 1) { - positionSuggest(); - suggestContainer.style.display = 'block'; - } - }); - - // 点击页面其他区域隐藏提示 - document.addEventListener('click', function(e) { - if (e.target !== input && !suggestContainer.contains(e.target)) { - suggestContainer.style.display = 'none'; - } - }); - - // 窗口调整大小时重新定位 - window.addEventListener('resize', function() { - if (suggestContainer.style.display === 'block') { - positionSuggest(); - } - }); -} diff --git a/ht/inc/pubs.php b/ht/inc/pubs.php deleted file mode 100644 index e3c4b7a..0000000 --- a/ht/inc/pubs.php +++ /dev/null @@ -1,147 +0,0 @@ - $code, - 'msg' => $msg, - 'data' => $data - ]); - exit; -} - -/** - * 检查用户登录状态 - * @return array|bool 已登录返回用户信息数组,未登录返回false - */ -function checkLogin() { - session_start(); - if (isset($_SESSION['user']) && !empty($_SESSION['user']['id'])) { - return $_SESSION['user']; - } - return false; -} - -/** - * 检查管理员权限 - * @return bool 是否具有管理员权限 - */ -function checkAdmin() { - $user = checkLogin(); - if ($user && $user['irole'] == 1) { - return true; - } - return false; -} - -/** - * 输入安全过滤 - * @param mixed $data 需要过滤的数据 - * @return mixed 过滤后的数据 - */ -function safeFilter($data) { - if (is_array($data)) { - foreach ($data as $key => $val) { - $data[$key] = safeFilter($val); - } - } else { - // 去除空格 - $data = trim($data); - // 转义特殊字符 - $data = htmlspecialchars($data, ENT_QUOTES); - // 防止SQL注入 - $data = addslashes($data); - } - return $data; -} - -/** - * 系统日志记录 - * @param int $userId 用户ID - * @param string $action 操作类型 - * @param string $content 操作内容 - */ -function writeLog($userId, $action, $content = '') { - $conn = dbConnect(); - $table = getTable('logs'); - $userId = (int)$userId; - $action = $conn->real_escape_string($action); - $content = $conn->real_escape_string($content); - $ip = $_SERVER['REMOTE_ADDR']; - $time = date('Y-m-d H:i:s'); - - $sql = "INSERT INTO {$table} (user_id, action, idesc, ip, logtime) VALUES ($userId, '$action', '$content', '$ip', '$time')"; - $conn->query($sql); - $conn->close(); -} - -/** - * 权限检查函数 - * @param string $action 操作名称 - * @param bool $adminRequired 是否需要管理员权限 - * @return bool|array 成功返回用户信息,失败返回false - */ -function checkAuth($action, $adminRequired = false) { - $user = checkLogin(); - - // 未登录 - if (!$user) { - ajaxReturn(403, '请先登录后再操作'); - return false; - } - - // 需要管理员权限但不是管理员 - if ($adminRequired && $user['irole'] != 1) { - ajaxReturn(403, '权限不足,需要管理员权限'); - return false; - } - - return $user; -} - -/** - * 获取分页参数 - * @param int $total 总记录数 - * @param int $page 当前页码 - * @param int $pageSize 每页记录数 - * @return array 分页信息 - */ -function getPagination($total, $page = 1, $pageSize = 10) { - $page = max(1, intval($page)); - $pageSize = max(1, intval($pageSize)); - - $totalPage = ceil($total / $pageSize); - $totalPage = max(1, $totalPage); - $page = min($page, $totalPage); - - $offset = ($page - 1) * $pageSize; - - return [ - 'total' => $total, - 'page' => $page, - 'pageSize' => $pageSize, - 'totalPage' => $totalPage, - 'offset' => $offset - ]; -} - -/** - * 获取当前时间 - * @return string 格式化的时间字符串 - */ -function getCurrentTime() { - return date('Y-m-d H:i:s'); -} diff --git a/ht/inc/sqls.php b/ht/inc/sqls.php deleted file mode 100644 index 746aa39..0000000 --- a/ht/inc/sqls.php +++ /dev/null @@ -1,281 +0,0 @@ -conn = dbConnect(); - $this->prefix = $CONFIG['db']['prefix']; - } - - /** - * 析构函数,关闭数据库连接 - */ - public function __destruct() { - if ($this->conn) { - $this->conn->close(); - } - } - - /** - * 转义字符串 - * @param string $str 需要转义的字符串 - * @return string 转义后的字符串 - */ - public function escape($str) { - return $this->conn->real_escape_string($str); - } - - /** - * 获取带前缀的表名 - * @param string $table 表名 - * @return string 带前缀的表名 - */ - public function table($table) { - return $this->prefix . $table; - } - - /** - * 执行SQL查询 - * @param string $sql SQL语句 - * @return mysqli_result|bool 查询结果 - */ - public function query($sql) { - return $this->conn->query($sql); - } - - /** - * 获取一条记录 - * @param string $table 表名(不带前缀) - * @param string|array $where 查询条件 - * @param string $fields 返回字段 - * @return array|null 查询结果 - */ - public function getOne($table, $where = '', $fields = '*') { - $table = $this->table($table); - $whereStr = $this->parseWhere($where); - - $sql = "SELECT {$fields} FROM {$table} {$whereStr} LIMIT 1"; - $result = $this->query($sql); - - if ($result && $result->num_rows > 0) { - return $result->fetch_assoc(); - } - - return null; - } - - /** - * 获取多条记录 - * @param string $table 表名(不带前缀) - * @param string|array $where 查询条件 - * @param string $fields 返回字段 - * @param string $order 排序方式 - * @param string $limit 限制条数 - * @return array 查询结果 - */ - public function getAll($table, $where = '', $fields = '*', $order = '', $limit = '') { - $table = $this->table($table); - $whereStr = $this->parseWhere($where); - $orderStr = $order ? "ORDER BY {$order}" : ''; - $limitStr = $limit ? "LIMIT {$limit}" : ''; - - $sql = "SELECT {$fields} FROM {$table} {$whereStr} {$orderStr} {$limitStr}"; - $result = $this->query($sql); - - $rows = []; - if ($result) { - while ($row = $result->fetch_assoc()) { - $rows[] = $row; - } - } - - return $rows; - } - - /** - * 插入数据 - * @param string $table 表名(不带前缀) - * @param array $data 数据数组 - * @return int|bool 成功返回插入ID,失败返回false - */ - public function insert($table, $data) { - $table = $this->table($table); - - $fields = []; - $values = []; - - foreach ($data as $key => $value) { - $fields[] = "`{$key}`"; - if ($value === null) { - $values[] = "NULL"; - } else { - $values[] = "'" . $this->escape($value) . "'"; - } - } - - $fieldsStr = implode(', ', $fields); - $valuesStr = implode(', ', $values); - - $sql = "INSERT INTO {$table} ({$fieldsStr}) VALUES ({$valuesStr})"; - $result = $this->query($sql); - - if ($result) { - return $this->conn->insert_id; - } - - return false; - } - - /** - * 更新数据 - * @param string $table 表名(不带前缀) - * @param array $data 数据数组 - * @param string|array $where 更新条件 - * @return bool 更新结果 - */ - public function update($table, $data, $where) { - $table = $this->table($table); - $whereStr = $this->parseWhere($where); - - $set = []; - foreach ($data as $key => $value) { - if ($value === null) { - $set[] = "`{$key}` = NULL"; - } else { - $set[] = "`{$key}` = '" . $this->escape($value) . "'"; - } - } - - $setStr = implode(', ', $set); - - $sql = "UPDATE {$table} SET {$setStr} {$whereStr}"; - $result = $this->query($sql); - - return $result !== false; - } - - /** - * 删除数据 - * @param string $table 表名(不带前缀) - * @param string|array $where 删除条件 - * @return bool 删除结果 - */ - public function delete($table, $where) { - $table = $this->table($table); - $whereStr = $this->parseWhere($where); - - if (empty($whereStr)) { - return false; // 防止误删除全表 - } - - $sql = "DELETE FROM {$table} {$whereStr}"; - $result = $this->query($sql); - - return $result !== false; - } - - /** - * 获取记录数量 - * @param string $table 表名(不带前缀) - * @param string|array $where 查询条件 - * @return int 记录数量 - */ - public function count($table, $where = '') { - $table = $this->table($table); - $whereStr = $this->parseWhere($where); - - $sql = "SELECT COUNT(*) AS count FROM {$table} {$whereStr}"; - $result = $this->query($sql); - - if ($result && $result->num_rows > 0) { - $row = $result->fetch_assoc(); - return (int) $row['count']; - } - - return 0; - } - - /** - * 开始事务 - */ - public function startTransaction() { - $this->conn->autocommit(false); - } - - /** - * 提交事务 - */ - public function commit() { - $this->conn->commit(); - $this->conn->autocommit(true); - } - - /** - * 回滚事务 - */ - public function rollback() { - $this->conn->rollback(); - $this->conn->autocommit(true); - } - - /** - * 解析查询条件 - * @param string|array $where 查询条件 - * @return string 解析后的WHERE子句 - */ - private function parseWhere($where) { - if (empty($where)) { - return ''; - } - - // 如果是字符串,直接返回 - if (is_string($where)) { - return "WHERE {$where}"; - } - - // 如果是数组,解析为查询条件 - if (is_array($where)) { - $conditions = []; - - foreach ($where as $key => $value) { - if ($value === null) { - $conditions[] = "`{$key}` IS NULL"; - } else { - $conditions[] = "`{$key}` = '" . $this->escape($value) . "'"; - } - } - - return "WHERE " . implode(' AND ', $conditions); - } - - return ''; - } - - /** - * 获取最后的错误信息 - * @return string 错误信息 - */ - public function getError() { - return $this->conn->error; - } - - /** - * 获取最后执行的SQL影响行数 - * @return int 影响行数 - */ - public function affectedRows() { - return $this->conn->affected_rows; - } -} diff --git a/ht/index.php b/ht/index.php index da5c99a..7e899fc 100644 --- a/ht/index.php +++ b/ht/index.php @@ -1,372 +1,372 @@ -= 0) { - $whereConditions[] = "status = $status"; -} -if ($type >= 0) { - $whereConditions[] = "itype = $type"; -} - -// 当前时间,用于判断投票是否进行中 -$now = date('Y-m-d H:i:s'); -$whereStr = !empty($whereConditions) ? implode(' AND ', $whereConditions) : ''; - -// 获取总记录数 -$total = $db->count('vote', $whereStr); - -// 计算分页信息 -$pagination = getPagination($total, $page, $pageSize); - -// 获取投票列表 -$orderBy = "addtime DESC"; -$limit = "{$pagination['offset']}, {$pagination['pageSize']}"; -$voteList = $db->getAll('vote', $whereStr, '*', $orderBy, $limit); - -// 页面标题 -$pageTitle = "投票系统首页"; -?> - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - + 诗词收录 - 古诗词鉴赏平台 + - -
-
- - +
+
+

📜 诗词收录

+

收录经典诗词,传承中华文化

-
- - -
-

投票列表

- - -
-
-
-
- - + +
+
+ + +
+ +
+ +
-
- - +
+ + +
-
- - 重置 +
+
+ +
+ + +
+ +
+ + +
+ +
+ + +
+ +
+ + +
+ +
+ + +
+ +
+ +
+
+ +
+ + -
- - - - - - - -
- - $now) { - $voteStatus = '未开始'; - $statusClass = 'vote-status-pending'; - } elseif ($vote['endtime'] < $now) { - $voteStatus = '已结束'; - $statusClass = 'vote-status-ended'; - } else { - $voteStatus = '进行中'; - $statusClass = 'vote-status-active'; - } - } - ?> -
-
-

- - -

-
-
-

- - 100): ?>... -

-

类型:

-

时间:

-

浏览:

-
- -
- + +
+

🔧 开发者调试工具

+ + + +
- - - - -
-
-

暂无投票数据

-
-
- +
- - + + + - - diff --git a/ht/login.php b/ht/login.php deleted file mode 100644 index 6fb06f5..0000000 --- a/ht/login.php +++ /dev/null @@ -1,146 +0,0 @@ - - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
- -
- - - - - diff --git a/ht/p1/API文档.md b/ht/p1/API文档.md deleted file mode 100644 index 399f7fa..0000000 --- a/ht/p1/API文档.md +++ /dev/null @@ -1,503 +0,0 @@ -# 古诗文答题系统 API 文档 - -## 文件信息 -- **文件路径**: `p1/api.php` -- **功能描述**: 古诗文题目获取与答题系统 -- **编码格式**: UTF-8 -- **响应格式**: JSON - -## 安全认证 - -### Key 认证机制 -API 采用动态 Key 认证,防止接口被滥用。 - -#### 认证原理 -1. **客户端生成 Key**: 使用 `SHA256(时间戳 + 密钥)` 生成 -2. **服务端验证**: 验证 Key 是否在有效期内(默认 300 秒) -3. **Key 更新**: 每次成功请求后,服务端返回新的 `new_key` - -#### 密钥配置 -- **前端**: `api.js` 中的 `SECRET_KEY` 变量 -- **后端**: `api.php` 中的 `SECRET_KEY` 常量 -- **默认密钥**: `tzgsc_2026_secret_key` - -#### Key 生成算法 - -##### PHP -```php - String { - let timestamp = SystemTime::now() - .duration_since(UNIX_EPOCH) - .unwrap() - .as_secs(); - - let data = format!("{}{}", timestamp, SECRET_KEY); - let mut hasher = Sha256::new(); - hasher.update(data.as_bytes()); - let result = hasher.finalize(); - - hex::encode(result) -} - -// 使用示例 -fn main() { - let key = generate_key(); - let encoded_key = urlencoding::encode(&key); - let url = format!("api.php?id=1&key={}", encoded_key); - println!("{}", url); -} -``` - -### 请求限制 - -| 类型 | 限制 | 说明 | -|------|------|------| -| 无 Key 请求 | 10 次/分钟 | 基于 IP 地址限制 | -| 有 Key 请求 | 无限制 | 验证通过后无频率限制 | - -#### 限制配置 -```php -define('KEY_EXPIRE_TIME', 300); // Key 有效期(秒) -define('MAX_REQUESTS_NO_KEY', 10); // 无 Key 最大请求次数 -define('RATE_LIMIT_WINDOW', 60); // 限流时间窗口(秒) -``` - -## 接口信息 - -### 接口概述 -该接口用于获取古诗文题目、验证答案、获取提示信息,支持 GET 和 POST 请求方式。 - -### 请求参数 - -| 参数名 | 类型 | 必填 | 说明 | -|--------|------|------|------| -| id | string/int | 是 | 题目唯一标识符 | -| msg | string | 否 | 操作类型:答案序号/提示 | -| key | string | 否 | 认证密钥(推荐携带) | - -### 请求示例 - -#### 1. 获取题目 -``` -GET p1/api.php?id=1&key=xxx -``` - -POST 请求: -``` -POST p1/api.php -Content-Type: application/json - -{ - "id": "1", - "key": "xxx" -} -``` - -#### 2. 提交答案 -``` -GET p1/api.php?id=1&msg=1&key=xxx -``` - -POST 请求: -``` -POST p1/api.php -Content-Type: application/json - -{ - "id": "1", - "msg": "1", - "key": "xxx" -} -``` - -#### 3. 获取提示 -``` -GET p1/api.php?id=1&msg=提示&key=xxx -``` - -POST 请求: -``` -POST p1/api.php -Content-Type: application/json - -{ - "id": "1", - "msg": "提示", - "key": "xxx" -} -``` - -### 响应信息 - -#### 获取题目成功响应 -```json -{ - "success": true, - "new_key": "新的认证密钥", - "data": { - "id": "1", - "question": "题目内容", - "options": [ - { - "num": 1, - "text": "选项1" - }, - { - "num": 2, - "text": "选项2" - }, - { - "num": 3, - "text": "选项3" - }, - { - "num": 4, - "text": "选项4" - } - ], - "author": "作者", - "type": "描写类型", - "grade": "学习阶段", - "dynasty": "年代" - } -} -``` - -#### 答案正确响应 -```json -{ - "success": true, - "type": "correct", - "message": "恭喜你,回答正确。请继续下一题", - "next_question": { - "id": "2", - "question": "下一题题目", - "options": [ - ... - ], - "author": "作者", - "type": "描写类型", - "grade": "学习阶段", - "dynasty": "年代" - } -} -``` - -#### 答案错误响应 -```json -{ - "success": true, - "type": "wrong", - "message": "抱歉,答案不对哦。你可以回复提示获取该题的部分信息哦。" -} -``` - -#### 提示响应 -```json -{ - "success": true, - "type": "hint", - "message": "这是首描写[描写类型]的诗,你在[学习阶段]学过它。" -} -``` - -#### 获取失败响应 -```json -{ - "success": false, - "message": "抱歉,获取出现错误。" -} -``` - -#### 错误参数响应 -```json -{ - "success": false, - "message": "缺少必要参数: id" -} -``` - -#### 不支持的请求方法 -```json -{ - "success": false, - "message": "不支持的请求方法" -} -``` - -#### 请求频率限制 -```json -{ - "success": false, - "message": "请求过于频繁,请稍后再试" -} -``` -HTTP 状态码: 429 - -## 核心功能说明 - -### 1. 题目数据来源 -- 从百度汉语 API 获取题目数据 -- API 地址: `https://hanyu.baidu.com/hanyu/ajax/pingce_data` - -### 2. 数据存储 -- 题目数据存储在 `data/tzgsc/` 目录 -- 文件格式: `.json` -- 文件命名: `{id}.json` -- JSON 缓存: `data/tzgsc.json` - -### 3. 数据格式 -题目数据存储格式 (JSON): -```json -{ - "id": "1", - "question": "题目内容", - "options": [ - {"num": 1, "text": "选项1"}, - {"num": 2, "text": "选项2"}, - {"num": 3, "text": "选项3"}, - {"num": 4, "text": "选项4"} - ], - "author": "作者", - "type": "描写类型", - "grade": "学习阶段", - "dynasty": "年代", - "correct_answer": 1 -} -``` - -### 4. 核心函数 - -#### get_question($id) -获取并返回题目 -- **参数**: $id - 题目 ID -- **返回**: 包含题目信息的数组 - -#### submit_answer($id, $msg) -提交答案并返回结果 -- **参数**: - - $id - 题目 ID - - $msg - 答案序号或"提示" -- **返回**: 包含答题结果的数组 - -#### cj($data) -采集并缓存题目数据 -- **参数**: $data - API 返回的原始数据 -- **功能**: 解析题目数据,去重后保存到 JSON 文件 - -#### get_curl($url, $post, $referer, $cookie, $header, $ua, $nobaody) -发送 HTTP 请求 -- **参数**: - - $url - 请求地址 - - $post - POST 数据 - - $referer - 来源地址 - - $cookie - Cookie - - $header - 是否返回头部 - - $ua - User-Agent - - $nobaody - 是否不返回内容 -- **功能**: 使用 cURL 发送 HTTP 请求,支持 SSL 和 GZIP 压缩 - -#### replace_unicode_escape_sequence($match) -Unicode 转义序列转换 -- **参数**: $match - 匹配到的 Unicode 序列 -- **返回**: UTF-8 编码的字符串 -- **功能**: 将 Unicode 转义序列转换为 UTF-8 字符 - -## 目录结构 -``` -p1/ -├── api.php # API 接口文件 -├── index.php # 前端页面(服务端生成初始 Key) -├── api.js # 前端交互脚本 -└── data/ - ├── tzgsc.json # 题目缓存文件 - ├── rate_limit/ # 请求限制记录目录 - └── tzgsc/ - └── [id].json # 题目数据文件 -``` - -## 注意事项 -1. 确保 `data/tzgsc/` 目录具有写入权限 -2. API 依赖百度汉语接口,需确保网络连接正常 -3. 题目数据会缓存到本地,避免重复请求 -4. 答案验证时会读取本地保存的题目数据文件 -5. 支持 Unicode 编码处理和 GZIP 压缩响应 -6. 支持 GET 和 POST 两种请求方式 -7. 所有响应均为 JSON 格式 diff --git a/ht/p1/api.js b/ht/p1/api.js deleted file mode 100644 index f5f04c7..0000000 --- a/ht/p1/api.js +++ /dev/null @@ -1,344 +0,0 @@ -(function() { - 'use strict'; - - var state = { - currentId: 1, - correctCount: 0, - totalCount: 0, - selectedOption: null, - isLoading: false, - answered: false, - currentKey: window.INITIAL_KEY || null - }; - - var elements = { - questionCard: document.getElementById('questionCard'), - navigation: document.getElementById('navigation'), - details: document.getElementById('details'), - loading: document.getElementById('loading'), - correctCount: document.getElementById('correctCount'), - totalCount: document.getElementById('totalCount'), - feedback: document.getElementById('feedback'), - feedbackIcon: document.getElementById('feedbackIcon'), - feedbackText: document.getElementById('feedbackText'), - overlay: document.getElementById('overlay'), - detailAuthor: document.getElementById('detailAuthor'), - detailDynasty: document.getElementById('detailDynasty'), - detailType: document.getElementById('detailType'), - detailGrade: document.getElementById('detailGrade') - }; - - function getUrlParam(name) { - var urlParams = new URLSearchParams(window.location.search); - return urlParams.get(name); - } - - function setUrlParam(name, value) { - var url = new URL(window.location.href); - url.searchParams.set(name, value); - window.history.replaceState({}, '', url); - } - - function fetchData(url, callback, errorCallback) { - if (!state.currentKey) { - errorCallback('未初始化 Key'); - return; - } - - var separator = url.indexOf('?') !== -1 ? '&' : '?'; - var fullUrl = url + separator + 'key=' + encodeURIComponent(state.currentKey); - - var xhr = new XMLHttpRequest(); - xhr.open('GET', fullUrl, true); - xhr.setRequestHeader('Accept', 'application/json'); - - xhr.onreadystatechange = function() { - if (xhr.readyState === 4) { - if (xhr.status === 200) { - try { - var response = JSON.parse(xhr.responseText); - if (response.new_key) { - state.currentKey = response.new_key; - } - callback(response); - } catch (e) { - errorCallback('解析响应失败'); - } - } else if (xhr.status === 429) { - errorCallback('请求过于频繁,请稍后再试'); - } else { - errorCallback('请求失败,状态码: ' + xhr.status); - } - } - }; - - xhr.onerror = function() { - errorCallback('网络错误'); - }; - - xhr.send(); - } - - function fetchQuestion(id) { - if (state.isLoading) return; - - state.isLoading = true; - state.answered = false; - state.selectedOption = null; - - showLoading(); - - fetchData('api.php?id=' + id, function(response) { - state.isLoading = false; - - if (response.success) { - renderQuestion(response.data); - updateNavigation(id); - updateDetails(response.data); - } else { - showError(response.message || '获取题目失败'); - } - }, function(error) { - state.isLoading = false; - showError(error); - }); - } - - function submitAnswer(id, answer) { - if (state.isLoading || state.answered) return; - - state.isLoading = true; - - fetchData('api.php?id=' + id + '&msg=' + answer, function(response) { - state.isLoading = false; - - if (response.success) { - state.totalCount++; - updateStats(); - - if (response.type === 'correct') { - state.correctCount++; - updateStats(); - showFeedback('correct', '🎉 ' + response.message); - markOption(answer, 'correct'); - - setTimeout(function() { - hideFeedback(); - if (response.next_question) { - state.currentId++; - setUrlParam('id', state.currentId); - renderQuestion(response.next_question); - updateNavigation(state.currentId); - updateDetails(response.next_question); - } else { - state.currentId++; - setUrlParam('id', state.currentId); - fetchQuestion(state.currentId); - } - }, 1500); - } else if (response.type === 'wrong') { - showFeedback('wrong', '😢 ' + response.message); - markOption(answer, 'wrong'); - setTimeout(function() { - hideFeedback(); - clearOptionMark(answer); - }, 2000); - } else if (response.type === 'hint') { - showHintMessage(response.message); - } - } else { - showFeedback('wrong', response.message || '提交失败'); - setTimeout(hideFeedback, 2000); - } - }, function(error) { - state.isLoading = false; - showFeedback('wrong', error); - setTimeout(hideFeedback, 2000); - }); - } - - function getHint(id) { - if (state.isLoading) return; - - state.isLoading = true; - - fetchData('api.php?id=' + id + '&msg=提示', function(response) { - state.isLoading = false; - - if (response.success && response.type === 'hint') { - showHintMessage(response.message); - } else { - showFeedback('wrong', response.message || '获取提示失败'); - setTimeout(hideFeedback, 2000); - } - }, function(error) { - state.isLoading = false; - showFeedback('wrong', error); - setTimeout(hideFeedback, 2000); - }); - } - - function showLoading() { - elements.questionCard.innerHTML = '
加载中
'; - elements.details.style.display = 'none'; - } - - function showError(message) { - elements.questionCard.innerHTML = - '
' + - '

❌ ' + message + '

' + - '' + - '
'; - elements.details.style.display = 'none'; - } - - function renderQuestion(data) { - var html = '第 ' + data.id + ' 题'; - html += '
' + escapeHtml(data.question) + '
'; - html += '
'; - - data.options.forEach(function(option) { - html += ''; - }); - - html += '
'; - html += ''; - html += '
'; - - elements.questionCard.innerHTML = html; - } - - function updateNavigation(currentId) { - var html = ''; - var start = Math.max(1, currentId - 4); - var end = currentId + 5; - - for (var i = start; i <= end; i++) { - var activeClass = i === currentId ? ' active' : ''; - html += ''; - } - - elements.navigation.innerHTML = html; - } - - function updateDetails(data) { - elements.detailAuthor.textContent = data.author || '-'; - elements.detailDynasty.textContent = data.dynasty || '-'; - elements.detailType.textContent = data.type || '-'; - elements.detailGrade.textContent = data.grade || '-'; - elements.details.style.display = 'grid'; - } - - function updateStats() { - elements.correctCount.textContent = state.correctCount; - elements.totalCount.textContent = state.totalCount; - } - - function selectOption(num) { - if (state.answered || state.isLoading) return; - - var buttons = document.querySelectorAll('.option-btn'); - buttons.forEach(function(btn) { - btn.classList.remove('selected'); - }); - - var selectedBtn = document.querySelector('.option-btn[data-num="' + num + '"]'); - if (selectedBtn) { - selectedBtn.classList.add('selected'); - } - - state.selectedOption = num; - submitAnswer(state.currentId, num); - } - - function markOption(num, type) { - var btn = document.querySelector('.option-btn[data-num="' + num + '"]'); - if (btn) { - btn.classList.add(type); - } - } - - function clearOptionMark(num) { - var btn = document.querySelector('.option-btn[data-num="' + num + '"]'); - if (btn) { - btn.classList.remove('wrong', 'selected'); - } - } - - function showFeedback(type, message) { - elements.feedback.className = 'feedback show ' + type; - elements.feedbackIcon.textContent = type === 'correct' ? '🎉' : '😢'; - elements.feedbackText.textContent = message.replace(/^[🎉😢]\s*/, ''); - elements.overlay.classList.add('show'); - } - - function hideFeedback() { - elements.feedback.classList.remove('show'); - elements.overlay.classList.remove('show'); - } - - function showHintMessage(message) { - var hintEl = document.getElementById('hintMessage'); - if (hintEl) { - hintEl.textContent = '💡 ' + message; - hintEl.classList.add('show'); - } - } - - function goToQuestion(id) { - if (state.isLoading) return; - - state.currentId = id; - state.answered = false; - state.selectedOption = null; - setUrlParam('id', id); - fetchQuestion(id); - } - - function goToRandomQuestion() { - if (state.isLoading) return; - - var randomId = Math.floor(Math.random() * 500) + 1; - goToQuestion(randomId); - } - - function retry() { - fetchQuestion(state.currentId); - } - - function escapeHtml(text) { - var div = document.createElement('div'); - div.textContent = text; - return div.innerHTML; - } - - function init() { - var idParam = getUrlParam('id'); - if (idParam) { - state.currentId = parseInt(idParam, 10) || 1; - } else { - state.currentId = Math.floor(Math.random() * 500) + 1; - } - - fetchQuestion(state.currentId); - } - - window.PoetryQuiz = { - selectOption: selectOption, - getHint: function() { getHint(state.currentId); }, - goToQuestion: goToQuestion, - goToRandomQuestion: goToRandomQuestion, - retry: retry - }; - - if (document.readyState === 'loading') { - document.addEventListener('DOMContentLoaded', init); - } else { - init(); - } -})(); diff --git a/ht/p1/api.php b/ht/p1/api.php deleted file mode 100644 index 8ea8e91..0000000 --- a/ht/p1/api.php +++ /dev/null @@ -1,375 +0,0 @@ - false, - 'message' => $message - ], $status_code); -} - -function generate_new_key($timestamp = null) { - if ($timestamp === null) { - $timestamp = time(); - } - $data = $timestamp . SECRET_KEY; - return hash('sha256', $data); -} - -function verify_key($key, &$new_key = null) { - if (empty($key)) { - return false; - } - - $current_time = time(); - - for ($i = 0; $i <= KEY_EXPIRE_TIME; $i++) { - $expected_key = generate_new_key($current_time - $i); - if (hash_equals($expected_key, $key)) { - $new_key = generate_new_key(); - return true; - } - } - - return false; -} - -function get_client_ip() { - $ip = ''; - if (!empty($_SERVER['HTTP_CLIENT_IP'])) { - $ip = $_SERVER['HTTP_CLIENT_IP']; - } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) { - $ip = explode(',', $_SERVER['HTTP_X_FORWARDED_FOR'])[0]; - } elseif (!empty($_SERVER['REMOTE_ADDR'])) { - $ip = $_SERVER['REMOTE_ADDR']; - } - return trim($ip); -} - -function check_rate_limit($ip) { - $limit_file = "data/rate_limit/" . md5($ip) . ".json"; - - if (!is_dir("data/rate_limit")) { - mkdir("data/rate_limit", 0755, true); - } - - $current_time = time(); - $requests = []; - - if (file_exists($limit_file)) { - $requests = json_decode(file_get_contents($limit_file), true) ?: []; - } - - $requests = array_filter($requests, function($time) use ($current_time) { - return ($current_time - $time) < RATE_LIMIT_WINDOW; - }); - - return count($requests); -} - -function record_request($ip) { - $limit_file = "data/rate_limit/" . md5($ip) . ".json"; - - if (!is_dir("data/rate_limit")) { - mkdir("data/rate_limit", 0755, true); - } - - $current_time = time(); - $requests = []; - - if (file_exists($limit_file)) { - $requests = json_decode(file_get_contents($limit_file), true) ?: []; - } - - $requests[] = $current_time; - - $requests = array_filter($requests, function($time) use ($current_time) { - return ($current_time - $time) < RATE_LIMIT_WINDOW; - }); - - file_put_contents($limit_file, json_encode(array_values($requests))); -} - -function get_key_param() { - if (isset($_GET['key'])) { - return $_GET['key']; - } - if (isset($_POST['key'])) { - return $_POST['key']; - } - $input = json_decode(file_get_contents('php://input'), true); - if (isset($input['key'])) { - return $input['key']; - } - return null; -} - -$method = $_SERVER['REQUEST_METHOD']; -$key = get_key_param(); -$ip = get_client_ip(); -$new_key = null; - -if (!verify_key($key, $new_key)) { - $request_count = check_rate_limit($ip); - - if ($request_count >= MAX_REQUESTS_NO_KEY) { - error_response('请求过于频繁,请稍后再试', 429); - } - - record_request($ip); -} - -if ($method === 'GET') { - $id = isset($_GET['id']) ? $_GET['id'] : ''; - $msg = isset($_GET['msg']) ? $_GET['msg'] : ''; - - if (empty($id)) { - error_response('缺少必要参数: id'); - } - - if (empty($msg)) { - $result = get_question($id); - if ($new_key) { - $result['new_key'] = $new_key; - } - send_json_response($result); - } else { - $result = submit_answer($id, $msg); - if ($new_key) { - $result['new_key'] = $new_key; - } - send_json_response($result); - } -} elseif ($method === 'POST') { - $input = json_decode(file_get_contents('php://input'), true); - $id = isset($input['id']) ? $input['id'] : ''; - $msg = isset($input['msg']) ? $input['msg'] : ''; - - if (empty($id)) { - error_response('缺少必要参数: id'); - } - - if (empty($msg)) { - $result = get_question($id); - if ($new_key) { - $result['new_key'] = $new_key; - } - send_json_response($result); - } else { - $result = submit_answer($id, $msg); - if ($new_key) { - $result['new_key'] = $new_key; - } - send_json_response($result); - } -} else { - error_response('不支持的请求方法', 405); -} - -function get_question($id) { - $data = get_curl("https://hanyu.baidu.com/hanyu/ajax/pingce_data"); - $data = preg_replace_callback('/\\\\u([0-9a-f]{4})/i', 'replace_unicode_escape_sequence', $data); - - $cj = cj($data); - - $s = preg_match_all('/{"question_content":"(.*?)","type":{"person":"(.*?)","type":"(.*?)","grade":"(.*?)","dynasty":"(.*?)"},"option_answers":\[(.*?)\]}/', $data, $t); - - if ($s == 0) { - return [ - 'success' => false, - 'message' => '抱歉,获取出现错误。' - ]; - } - - $tm = $t[1][0]; - $z = $t[2][0]; - $l = $t[3][0]; - $n = $t[4][0]; - $nd = $t[5][0]; - - preg_match_all('/{"answer_content":"(.*?)","is_standard_answer":(.*?)}/', $t[6][0], $d); - - $options = []; - $correct_answer = null; - - for ($i = 0; $i < 4; $i++) { - $d1 = $d[1][$i]; - $p = $d[2][$i]; - $option_num = $i + 1; - - $options[] = [ - 'num' => $option_num, - 'text' => $d1 - ]; - - if ($p == "1") { - $correct_answer = $option_num; - } - } - - $question_data = [ - 'id' => $id, - 'question' => $tm, - 'options' => $options, - 'author' => $z, - 'type' => $l, - 'grade' => $n, - 'dynasty' => $nd, - 'correct_answer' => $correct_answer - ]; - - file_put_contents("data/tzgsc/" . $id . ".json", json_encode($question_data, JSON_UNESCAPED_UNICODE)); - - return [ - 'success' => true, - 'data' => [ - 'id' => $id, - 'question' => $tm, - 'options' => $options, - 'author' => $z, - 'type' => $l, - 'grade' => $n, - 'dynasty' => $nd - ] - ]; -} - -function submit_answer($id, $msg) { - $data_file = "data/tzgsc/" . $id . ".json"; - - if (!file_exists($data_file)) { - return [ - 'success' => false, - 'message' => '题目数据不存在,请先获取题目' - ]; - } - - $question_data = json_decode(file_get_contents($data_file), true); - - if ($msg === "提示") { - return [ - 'success' => true, - 'type' => 'hint', - 'message' => '这是首描写' . $question_data['type'] . '的诗,你在' . $question_data['grade'] . '学过它。' - ]; - } - - if ($msg == $question_data['correct_answer']) { - $next_id = $id + 1; - $next_question = get_question($next_id); - - return [ - 'success' => true, - 'type' => 'correct', - 'message' => '恭喜你,回答正确。请继续下一题', - 'next_question' => $next_question['success'] ? $next_question['data'] : null - ]; - } else { - return [ - 'success' => true, - 'type' => 'wrong', - 'message' => '抱歉,答案不对哦。你可以回复提示获取该题的部分信息哦。' - ]; - } -} - -function cj($data) { - if (!$data) return; - - $s = preg_match_all('/{"question_content":"(.*?)","type":(.*?)}]}/', $data, $d); - if ($s == 0) return; - - $json_file = "data/tzgsc.json"; - - $existing = []; - if (file_exists($json_file)) { - $content = file_get_contents($json_file); - $existing = json_decode($content, true); - if (!is_array($existing)) { - $existing = []; - } - } - - $existing_questions = []; - foreach ($existing as $item) { - if (isset($item['question_content'])) { - $existing_questions[$item['question_content']] = true; - } - } - - for ($i = 0; $i < $s; $i++) { - $d1 = $d[1][$i]; - $d2 = $d[2][$i]; - - if (!isset($existing_questions[$d1])) { - $new_item = [ - 'question_content' => $d1, - 'type' => json_decode('{' . $d2, true) - ]; - if ($new_item['type']) { - $existing[] = $new_item; - $existing_questions[$d1] = true; - } - } - } - - file_put_contents($json_file, json_encode($existing, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT)); -} - -function get_curl($url, $post = 0, $referer = 1, $cookie = 0, $header = 0, $ua = 0, $nobaody = 0) { - $ch = curl_init(); - curl_setopt($ch, CURLOPT_URL, $url); - curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); - curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false); - $httpheader[] = "Accept:application/json"; - $httpheader[] = "Accept-Encoding:gzip,deflate,sdch"; - $httpheader[] = "Accept-Language:zh-CN,zh;q=0.8"; - $httpheader[] = "Connection:close"; - curl_setopt($ch, CURLOPT_HTTPHEADER, $httpheader); - if ($post) { - curl_setopt($ch, CURLOPT_POST, 1); - curl_setopt($ch, CURLOPT_POSTFIELDS, $post); - } - if ($header) { - curl_setopt($ch, CURLOPT_HEADER, TRUE); - } - if ($cookie) { - curl_setopt($ch, CURLOPT_DICTAPP_MID, $cookie); - } - if ($referer) { - if ($referer == 1) { - curl_setopt($ch, CURLOPT_REFERER, 'http://m.qzone.com/infocenter?g_f='); - } else { - curl_setopt($ch, CURLOPT_REFERER, $referer); - } - } - if ($ua) { - curl_setopt($ch, CURLOPT_USERAGENT, $ua); - } else { - curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Linux; U; Android 4.4.1; zh-cn) AppleWebKit/533.1 (KHTML, like Gecko)Version/4.0 MQQBrowser/5.5 Mobile Safari/533.1'); - } - if ($nobaody) { - curl_setopt($ch, CURLOPT_NOBODY, 1); - } - curl_setopt($ch, CURLOPT_ENCODING, "gzip"); - curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); - $ret = curl_exec($ch); - curl_close($ch); - return $ret; -} -?> diff --git a/ht/p1/data/tzgsc.json b/ht/p1/data/tzgsc.json deleted file mode 100644 index e772c95..0000000 --- a/ht/p1/data/tzgsc.json +++ /dev/null @@ -1,5456 +0,0 @@ -[ - { - "question_content": "撩乱边愁听不尽,“________”", - "type": { - "person": "王昌龄", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "孤城遥望玉门关", - "is_standard_answer": 0 - }, - { - "answer_content": "高高秋月照长城", - "is_standard_answer": 1 - }, - { - "answer_content": "总是关山旧别情", - "is_standard_answer": 0 - }, - { - "answer_content": "山北山南总是烽", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "大雨落幽燕,白浪滔天,“________”", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "初中", - "dynasty": "近现代" - }, - "option_answers": [ - { - "answer_content": "一片汪洋都不见", - "is_standard_answer": 0 - }, - { - "answer_content": "秦皇岛外打鱼船", - "is_standard_answer": 1 - }, - { - "answer_content": "无限江山", - "is_standard_answer": 0 - }, - { - "answer_content": "知向谁边", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“__”一片月,万户捣衣声", - "type": { - "person": "李白", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "天上", - "is_standard_answer": 0 - }, - { - "answer_content": "杭州", - "is_standard_answer": 0 - }, - { - "answer_content": "长安", - "is_standard_answer": 1 - }, - { - "answer_content": "人间", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "小楼昨夜又东风,“_________”", - "type": { - "person": "李煜 ", - "type": "婉约", - "grade": "高中", - "dynasty": "五代" - }, - "option_answers": [ - { - "answer_content": "恰似一春江水项东流", - "is_standard_answer": 0 - }, - { - "answer_content": "恰似故人远来载乡愁", - "is_standard_answer": 0 - }, - { - "answer_content": "故国不堪回首月明中", - "is_standard_answer": 1 - }, - { - "answer_content": "珠帘泛婆娑湿衣袖", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "诗人看到了什么写出了“忽如一夜春风来,千树万树梨花开”?", - "type": { - "person": "岑参 ", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "霜", - "is_standard_answer": 0 - }, - { - "answer_content": "梨花", - "is_standard_answer": 0 - }, - { - "answer_content": "雨", - "is_standard_answer": 0 - }, - { - "answer_content": "雪", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "李清照在《如梦令·常记溪亭日暮》中将小船误入了哪里?", - "type": { - "person": "李清照", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "荷花池", - "is_standard_answer": 1 - }, - { - "answer_content": "芦苇荡", - "is_standard_answer": 0 - }, - { - "answer_content": "水榭中", - "is_standard_answer": 0 - }, - { - "answer_content": "假山旁", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "李白与哪两位好友喝酒,写下了名作《将进酒》?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "岑勋、元稹", - "is_standard_answer": 0 - }, - { - "answer_content": "元丹丘、王维", - "is_standard_answer": 0 - }, - { - "answer_content": "岑勋、白居易", - "is_standard_answer": 0 - }, - { - "answer_content": "岑勋、元丹丘", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“执子之手,与子偕老”出自《诗经》,它最初指代的是什么感情?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "先秦" - }, - "option_answers": [ - { - "answer_content": "战友情", - "is_standard_answer": 1 - }, - { - "answer_content": "知己情", - "is_standard_answer": 0 - }, - { - "answer_content": "父母情", - "is_standard_answer": 0 - }, - { - "answer_content": "夫妻情", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“借问汉宫谁得似,可怜飞燕倚新妆”,这个和赵飞燕相似的女子是谁?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "班婕妤", - "is_standard_answer": 0 - }, - { - "answer_content": "貂蝉", - "is_standard_answer": 0 - }, - { - "answer_content": "王昭君", - "is_standard_answer": 0 - }, - { - "answer_content": "杨玉环", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“相貌丑陋却才华横溢,拒绝徒弟追求,被称作花间词派鼻祖”的是谁?", - "type": { - "person": "温庭筠", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "温庭筠", - "is_standard_answer": 1 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - }, - { - "answer_content": "李煜", - "is_standard_answer": 0 - }, - { - "answer_content": "元稹", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "春宵一刻值千金,“________”", - "type": { - "person": "苏轼", - "type": "春天", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "从此君王不早朝", - "is_standard_answer": 0 - }, - { - "answer_content": "待晓堂前拜舅姑", - "is_standard_answer": 0 - }, - { - "answer_content": "花有清香月有阴", - "is_standard_answer": 1 - }, - { - "answer_content": "赌书消得泼茶香", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "汉乐府《江南》中鱼戏莲叶东下一句", - "type": { - "person": "苏轼", - "type": "江南", - "grade": "小学", - "dynasty": "汉朝" - }, - "option_answers": [ - { - "answer_content": "鱼戏莲叶南", - "is_standard_answer": 0 - }, - { - "answer_content": "鱼戏莲叶中", - "is_standard_answer": 0 - }, - { - "answer_content": "鱼戏莲叶北", - "is_standard_answer": 0 - }, - { - "answer_content": "鱼戏莲叶西", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "几处早莺争暖树,“________”", - "type": { - "person": "白居易", - "type": "江南", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "草色遥看近却无", - "is_standard_answer": 0 - }, - { - "answer_content": "绿杨阴里白沙堤", - "is_standard_answer": 0 - }, - { - "answer_content": "谁家新燕啄春泥", - "is_standard_answer": 1 - }, - { - "answer_content": "浅草才能没马蹄", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "春眠不觉晓,“________”", - "type": { - "person": "孟浩然", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "花落知多少", - "is_standard_answer": 0 - }, - { - "answer_content": "处处蚊子咬", - "is_standard_answer": 0 - }, - { - "answer_content": "处处闻啼鸟", - "is_standard_answer": 1 - }, - { - "answer_content": "润物细无声", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "范仲淹在《江上渔者》中写到最爱什么鱼?", - "type": { - "person": "范仲淹", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "鳜鱼", - "is_standard_answer": 0 - }, - { - "answer_content": "鲤鱼", - "is_standard_answer": 0 - }, - { - "answer_content": "鲈鱼", - "is_standard_answer": 1 - }, - { - "answer_content": "草鱼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "天下才有一石,谁占了八斗?", - "type": { - "person": "谢灵运", - "type": "豪放", - "grade": "课外", - "dynasty": "晋朝" - }, - "option_answers": [ - { - "answer_content": "曹丕", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - }, - { - "answer_content": "谢灵运", - "is_standard_answer": 0 - }, - { - "answer_content": "曹植", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "王维的“独在异乡为异客,每逢佳节倍思亲”,佳节指的是什么节日?", - "type": { - "person": "王维", - "type": "思乡", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "重阳节", - "is_standard_answer": 1 - }, - { - "answer_content": "中秋节", - "is_standard_answer": 0 - }, - { - "answer_content": "元宵节", - "is_standard_answer": 0 - }, - { - "answer_content": "端午节", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“但使龙城飞将在,不教胡马度阴山”中飞将指的是谁?", - "type": { - "person": "王昌龄", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "周亚夫", - "is_standard_answer": 0 - }, - { - "answer_content": "李广", - "is_standard_answer": 1 - }, - { - "answer_content": "卫青", - "is_standard_answer": 0 - }, - { - "answer_content": "霍去病", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“群山万壑赴荆门,生长明妃尚有村”,明妃指的是?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "文成公主", - "is_standard_answer": 0 - }, - { - "answer_content": "王昭君", - "is_standard_answer": 1 - }, - { - "answer_content": "杨玉环", - "is_standard_answer": 0 - }, - { - "answer_content": "赵飞燕", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "明月出天山,“________”", - "type": { - "person": "李白", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "时鸣春涧中", - "is_standard_answer": 0 - }, - { - "answer_content": "呼作白玉盘", - "is_standard_answer": 0 - }, - { - "answer_content": "苍茫云海间", - "is_standard_answer": 1 - }, - { - "answer_content": "清泉石上流", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "漠漠水田飞白鹭,“________”", - "type": { - "person": "王维", - "type": "田园", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "两个黄鹂鸣翠柳", - "is_standard_answer": 0 - }, - { - "answer_content": "桃花流水鳜鱼肥", - "is_standard_answer": 0 - }, - { - "answer_content": "阴阴夏木啭黄鹂", - "is_standard_answer": 1 - }, - { - "answer_content": "两山排闼送青来", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "山一程,水一程,“________”", - "type": { - "person": "纳兰性德", - "type": "婉约", - "grade": "课外", - "dynasty": "清朝" - }, - "option_answers": [ - { - "answer_content": "身向榆关那畔行", - "is_standard_answer": 1 - }, - { - "answer_content": "聒碎乡心梦不成", - "is_standard_answer": 0 - }, - { - "answer_content": "山远天高烟水寒", - "is_standard_answer": 0 - }, - { - "answer_content": "自是人生长恨水长东", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "问君能有几多愁?“_________”", - "type": { - "person": "李煜 ", - "type": "婉约", - "grade": "高中", - "dynasty": "五代" - }, - "option_answers": [ - { - "answer_content": "恰似一江春水向东流", - "is_standard_answer": 1 - }, - { - "answer_content": "也拟泛轻舟", - "is_standard_answer": 0 - }, - { - "answer_content": "物是人非事事休", - "is_standard_answer": 0 - }, - { - "answer_content": "欲语泪先流", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“不以物喜,不以己悲”出自范仲淹的什么作品?", - "type": { - "person": "范仲淹", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "游钓台记", - "is_standard_answer": 0 - }, - { - "answer_content": "岳阳楼记", - "is_standard_answer": 1 - }, - { - "answer_content": "小石潭记", - "is_standard_answer": 0 - }, - { - "answer_content": "醉翁亭记", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "比喻高尚情操的“香草美人”出自哪里?", - "type": { - "person": "屈原", - "type": "豪放", - "grade": "高中", - "dynasty": "先秦" - }, - "option_answers": [ - { - "answer_content": "离骚", - "is_standard_answer": 1 - }, - { - "answer_content": "诗经", - "is_standard_answer": 0 - }, - { - "answer_content": "木兰辞", - "is_standard_answer": 0 - }, - { - "answer_content": "孔雀东南飞", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "骆宾王的《咏鹅》中,鹅掌是什么颜色的?", - "type": { - "person": "骆宾王", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "绿", - "is_standard_answer": 0 - }, - { - "answer_content": "红", - "is_standard_answer": 1 - }, - { - "answer_content": "灰", - "is_standard_answer": 0 - }, - { - "answer_content": "白", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“二十四桥明月夜,玉人何处教吹箫”是描写的哪个城市?", - "type": { - "person": "杜牧", - "type": "江南", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "扬州", - "is_standard_answer": 1 - }, - { - "answer_content": "苏州", - "is_standard_answer": 0 - }, - { - "answer_content": "杭州", - "is_standard_answer": 0 - }, - { - "answer_content": "南京", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“今日听君歌一曲,暂凭杯酒长精神”,这个君是谁?", - "type": { - "person": "刘禹锡", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李白", - "is_standard_answer": 0 - }, - { - "answer_content": "白居易", - "is_standard_answer": 1 - }, - { - "answer_content": "王维", - "is_standard_answer": 0 - }, - { - "answer_content": "刘禹锡", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "对名妓薛涛始乱终弃,写出“曾经沧海难为水,除却巫山不是云”的诗人是谁?", - "type": { - "person": "元稹", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李商隐", - "is_standard_answer": 0 - }, - { - "answer_content": "元稹", - "is_standard_answer": 1 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - }, - { - "answer_content": "刘禹锡", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "离离原上草,“________”", - "type": { - "person": "白居易", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "春风吹又生", - "is_standard_answer": 0 - }, - { - "answer_content": "晴翠接荒城", - "is_standard_answer": 0 - }, - { - "answer_content": "一岁一枯荣", - "is_standard_answer": 1 - }, - { - "answer_content": "萋萋满别情", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "九曲黄河万里沙,“________”", - "type": { - "person": "刘禹锡", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "咆哮万里触龙门", - "is_standard_answer": 0 - }, - { - "answer_content": "浪淘风簸自天涯", - "is_standard_answer": 1 - }, - { - "answer_content": "五千仞岳上摩天", - "is_standard_answer": 0 - }, - { - "answer_content": "万里写入胸怀间", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”西北望,射天狼", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "十年生死两茫茫", - "is_standard_answer": 0 - }, - { - "answer_content": "会挽雕弓如满月", - "is_standard_answer": 1 - }, - { - "answer_content": "老夫聊发少年狂", - "is_standard_answer": 0 - }, - { - "answer_content": "为报倾城随太守", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "张继那首有名的《枫桥夜泊》中,听到寒山寺的钟声,寒山寺在哪个城市?", - "type": { - "person": "张继", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "扬州", - "is_standard_answer": 0 - }, - { - "answer_content": "杭州", - "is_standard_answer": 0 - }, - { - "answer_content": "苏州", - "is_standard_answer": 1 - }, - { - "answer_content": "临安", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "白居易说“江南好,风景旧曾谙”,你知道白居易最忆的是江南哪里么?", - "type": { - "person": "白居易", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "扬州", - "is_standard_answer": 0 - }, - { - "answer_content": "杭州", - "is_standard_answer": 1 - }, - { - "answer_content": "吴宫", - "is_standard_answer": 0 - }, - { - "answer_content": "姑苏", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“白日放歌须纵酒,青春作伴好还乡”,诗人是去哪里呢?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "金陵", - "is_standard_answer": 0 - }, - { - "answer_content": "长安", - "is_standard_answer": 0 - }, - { - "answer_content": "襄阳", - "is_standard_answer": 0 - }, - { - "answer_content": "洛阳", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“朱雀桥边野草花,乌衣巷口夕阳斜”,乌衣巷在哪个城市?", - "type": { - "person": "刘禹锡", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "杭州", - "is_standard_answer": 0 - }, - { - "answer_content": "南京", - "is_standard_answer": 1 - }, - { - "answer_content": "西安", - "is_standard_answer": 0 - }, - { - "answer_content": "苏州", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“看朱成碧思纷纷,憔悴支离为忆君”,这个君指的是谁?", - "type": { - "person": "武则天", - "type": "思乡", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李世民", - "is_standard_answer": 0 - }, - { - "answer_content": "刘彻", - "is_standard_answer": 0 - }, - { - "answer_content": "李治", - "is_standard_answer": 1 - }, - { - "answer_content": "李隆基", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,从此萧郎是路人", - "type": { - "person": "崔郊", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "一入侯门深似海", - "is_standard_answer": 0 - }, - { - "answer_content": "侯门一入深如海", - "is_standard_answer": 1 - }, - { - "answer_content": "侯门一入深似海", - "is_standard_answer": 0 - }, - { - "answer_content": "一入侯门深如海", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“__”回首,那人却在,灯火阑珊处。", - "type": { - "person": "辛弃疾 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "蓦然", - "is_standard_answer": 1 - }, - { - "answer_content": "幕然", - "is_standard_answer": 0 - }, - { - "answer_content": "默然", - "is_standard_answer": 0 - }, - { - "answer_content": "墓然", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“松下问童子,言师采药去”,请问是谁在问童子?", - "type": { - "person": "贾岛", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "贺知章", - "is_standard_answer": 0 - }, - { - "answer_content": "贾岛", - "is_standard_answer": 1 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - }, - { - "answer_content": "松下", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“易求无价宝,难得有情郎”是谁写的?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "武则天", - "is_standard_answer": 0 - }, - { - "answer_content": "温庭筠", - "is_standard_answer": 0 - }, - { - "answer_content": "薛涛", - "is_standard_answer": 0 - }, - { - "answer_content": "鱼玄机", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“知章骑马似乘船,眼花落井水底眠”说的是谁?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "杜甫", - "is_standard_answer": 0 - }, - { - "answer_content": "贺知章", - "is_standard_answer": 1 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - }, - { - "answer_content": "王维", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“葡萄美酒夜光杯,欲饮琵琶马上催”是哪位诗人写的?", - "type": { - "person": "王翰", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李白", - "is_standard_answer": 0 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - }, - { - "answer_content": "王翰", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“西出阳关无故人”,阳关在哪个省?", - "type": { - "person": "王维", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "甘肃", - "is_standard_answer": 1 - }, - { - "answer_content": "西藏", - "is_standard_answer": 0 - }, - { - "answer_content": "新疆", - "is_standard_answer": 0 - }, - { - "answer_content": "内蒙", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "王安石在春节时写的“爆竹声中一岁除,春风送暖入屠苏”中屠苏指的是什么?", - "type": { - "person": "王安石", - "type": "思乡", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "茶", - "is_standard_answer": 0 - }, - { - "answer_content": "院子", - "is_standard_answer": 0 - }, - { - "answer_content": "祥瑞", - "is_standard_answer": 0 - }, - { - "answer_content": "酒", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "人间“__”芳菲尽,山寺桃花始盛开", - "type": { - "person": "白居易", - "type": "春天", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "六月", - "is_standard_answer": 0 - }, - { - "answer_content": "四月", - "is_standard_answer": 1 - }, - { - "answer_content": "三月", - "is_standard_answer": 0 - }, - { - "answer_content": "二月", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "多情自古伤离别,“_________”", - "type": { - "person": "柳永", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "应是良辰好景虚设", - "is_standard_answer": 0 - }, - { - "answer_content": "此恨不关风与月", - "is_standard_answer": 0 - }, - { - "answer_content": "此去经年", - "is_standard_answer": 0 - }, - { - "answer_content": "更那堪,冷落清秋节", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“晴空一鹤排云上,便引诗情到碧霄”描写的是什么季节?", - "type": { - "person": "刘禹锡", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "夏", - "is_standard_answer": 0 - }, - { - "answer_content": "秋", - "is_standard_answer": 1 - }, - { - "answer_content": "春", - "is_standard_answer": 0 - }, - { - "answer_content": "冬", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "辛弃疾的《清平乐·村居》中,小儿在做什么?", - "type": { - "person": "辛弃疾", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "剥莲蓬", - "is_standard_answer": 1 - }, - { - "answer_content": "除豆", - "is_standard_answer": 0 - }, - { - "answer_content": "钓鱼", - "is_standard_answer": 0 - }, - { - "answer_content": "织鸡笼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“两个黄鹂鸣翠柳,一行白鹭上青天”是哪位诗人写的?", - "type": { - "person": "杜甫", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "杜甫", - "is_standard_answer": 1 - }, - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "王维", - "is_standard_answer": 0 - }, - { - "answer_content": "杜牧", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《甄嬛传》里安陵容唱的“小山重叠金明灭”中小山指的是什么?", - "type": { - "person": "温庭筠", - "type": "婉约", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "画", - "is_standard_answer": 0 - }, - { - "answer_content": "眉妆", - "is_standard_answer": 1 - }, - { - "answer_content": "衣服", - "is_standard_answer": 0 - }, - { - "answer_content": "小小的山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "此曲只应天上有,人间“__”几回闻", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "只得", - "is_standard_answer": 0 - }, - { - "answer_content": "哪得", - "is_standard_answer": 0 - }, - { - "answer_content": "能得", - "is_standard_answer": 1 - }, - { - "answer_content": "值得", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "飞流直下三千尺,“____”银河落九天", - "type": { - "person": "李白", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "疑似", - "is_standard_answer": 0 - }, - { - "answer_content": "恰是", - "is_standard_answer": 0 - }, - { - "answer_content": "疑是", - "is_standard_answer": 1 - }, - { - "answer_content": "恰似", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "行到水穷处,“________”", - "type": { - "person": "王维", - "type": "田园", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王孙自可留", - "is_standard_answer": 0 - }, - { - "answer_content": "坐看云起时", - "is_standard_answer": 1 - }, - { - "answer_content": "独坐敬亭山", - "is_standard_answer": 0 - }, - { - "answer_content": "谈笑无还期", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“遥想公瑾当年,小乔初嫁了”,这个幸福的公瑾是谁?", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "孙权", - "is_standard_answer": 0 - }, - { - "answer_content": "刘备", - "is_standard_answer": 0 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - }, - { - "answer_content": "周瑜", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "孟浩然的《望洞庭赠张丞相》,张丞相是谁?", - "type": { - "person": "孟浩然", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "张行成", - "is_standard_answer": 0 - }, - { - "answer_content": "张籍", - "is_standard_answer": 0 - }, - { - "answer_content": "张苍", - "is_standard_answer": 0 - }, - { - "answer_content": "张九龄", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“春风得意马蹄疾,一日看尽长安花”是诗人考中了什么功名后写的?", - "type": { - "person": "孟郊", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "状元", - "is_standard_answer": 0 - }, - { - "answer_content": "进士", - "is_standard_answer": 1 - }, - { - "answer_content": "榜眼", - "is_standard_answer": 0 - }, - { - "answer_content": "探花", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“云想衣裳花想容,春风拂槛露华浓”中李白用什么花来描写杨贵妃之美?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "芍药", - "is_standard_answer": 0 - }, - { - "answer_content": "牡丹", - "is_standard_answer": 1 - }, - { - "answer_content": "荷花", - "is_standard_answer": 0 - }, - { - "answer_content": "海棠", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "小山重叠金明灭,“_________”", - "type": { - "person": "温庭筠", - "type": "婉约", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "鬓云欲度香腮雪", - "is_standard_answer": 1 - }, - { - "answer_content": "绿杨陌上多离别", - "is_standard_answer": 0 - }, - { - "answer_content": "十二楼中月自明", - "is_standard_answer": 0 - }, - { - "answer_content": "碧天如水夜云轻", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "不知细叶谁裁出,“________”", - "type": { - "person": "贺知章", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "二月春风似剪刀", - "is_standard_answer": 1 - }, - { - "answer_content": "二月春风吹杨柳", - "is_standard_answer": 0 - }, - { - "answer_content": "二月初惊见草芽", - "is_standard_answer": 0 - }, - { - "answer_content": "霜叶红于二月花", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "旧时王谢堂前燕,“_________”", - "type": { - "person": "刘禹锡", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "更深月色半人家", - "is_standard_answer": 0 - }, - { - "answer_content": "飞来飞去落谁家", - "is_standard_answer": 0 - }, - { - "answer_content": "飞入寻常百姓家", - "is_standard_answer": 1 - }, - { - "answer_content": "蓬门今始为君开", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,时鸣春涧中", - "type": { - "person": "王维", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "空山新雨后", - "is_standard_answer": 0 - }, - { - "answer_content": "月出惊山鸟", - "is_standard_answer": 1 - }, - { - "answer_content": "明月松间照", - "is_standard_answer": 0 - }, - { - "answer_content": "夜静春山空", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“惜秦皇汉武,略输文采;唐宗宋祖,稍逊风骚”,秦皇汉武分别指的是谁?", - "type": { - "person": "毛泽东", - "type": "豪放", - "grade": "初中", - "dynasty": "近代" - }, - "option_answers": [ - { - "answer_content": "嬴政、刘彻", - "is_standard_answer": 1 - }, - { - "answer_content": "胡亥、刘备", - "is_standard_answer": 0 - }, - { - "answer_content": "嬴政、刘邦", - "is_standard_answer": 0 - }, - { - "answer_content": "扶苏、刘秀", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "与“身无彩凤双飞翼,心有灵犀一点通”出自同一首诗的是?", - "type": { - "person": "李商隐", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "青鸟殷勤为探看", - "is_standard_answer": 0 - }, - { - "answer_content": "相见时难别亦难", - "is_standard_answer": 0 - }, - { - "answer_content": "昨夜星辰昨夜风", - "is_standard_answer": 1 - }, - { - "answer_content": "碧海青天夜夜心", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“此地别燕丹,壮士发冲冠”描写的是哪个历史事件?", - "type": { - "person": "骆宾王", - "type": "豪放", - "grade": "课外 ", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "赤壁之战", - "is_standard_answer": 0 - }, - { - "answer_content": "屈原沉江", - "is_standard_answer": 0 - }, - { - "answer_content": "荆轲刺秦", - "is_standard_answer": 1 - }, - { - "answer_content": "巨鹿之战", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "与“天涯何处无芳草”出自同一首诗的是?", - "type": { - "person": "苏轼", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "墙里秋千墙外道", - "is_standard_answer": 1 - }, - { - "answer_content": "伫倚危楼风细细", - "is_standard_answer": 0 - }, - { - "answer_content": "山长水阔知何处", - "is_standard_answer": 0 - }, - { - "answer_content": "衣带渐宽终不悔", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“故人西辞黄鹤楼,烟花三月下扬州”,请问下列哪个代称不是扬州?", - "type": { - "person": "李白", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "江都", - "is_standard_answer": 0 - }, - { - "answer_content": "广陵", - "is_standard_answer": 0 - }, - { - "answer_content": "临安", - "is_standard_answer": 1 - }, - { - "answer_content": "维扬", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,崔九堂前几度闻", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "岐王宅里寻常见", - "is_standard_answer": 1 - }, - { - "answer_content": "乌衣巷口夕阳斜", - "is_standard_answer": 0 - }, - { - "answer_content": "此曲只应天上有", - "is_standard_answer": 0 - }, - { - "answer_content": "正是江南好风景", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "关关雎鸠,在河之洲。窈窕淑女,君子“__”。", - "type": { - "person": "李白", - "type": "婉约", - "grade": "初中", - "dynasty": "先秦" - }, - "option_answers": [ - { - "answer_content": "好仇", - "is_standard_answer": 0 - }, - { - "answer_content": "好求", - "is_standard_answer": 0 - }, - { - "answer_content": "好浗", - "is_standard_answer": 0 - }, - { - "answer_content": "好逑", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "与《孔雀东南飞》并称“乐府双璧”的是?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "初中", - "dynasty": "南北朝" - }, - "option_answers": [ - { - "answer_content": "长歌行", - "is_standard_answer": 0 - }, - { - "answer_content": "离骚", - "is_standard_answer": 0 - }, - { - "answer_content": "木兰辞", - "is_standard_answer": 1 - }, - { - "answer_content": "蒹葭", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“座中泣下谁最多,江州司马青衫湿”,江州司马是谁?", - "type": { - "person": "白居易", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "白居易", - "is_standard_answer": 1 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "王维", - "is_standard_answer": 0 - }, - { - "answer_content": "元稹", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "写下“两情若是久长时,又岂在朝朝暮暮”,被称作“山抹微云君”的诗人是?", - "type": { - "person": "秦观 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "黄庭坚", - "is_standard_answer": 0 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "秦观", - "is_standard_answer": 1 - }, - { - "answer_content": "柳永", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "白居易的《长恨歌》最后一句?", - "type": { - "person": "白居易", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "在地愿为连理枝", - "is_standard_answer": 0 - }, - { - "answer_content": "一别音容两渺茫", - "is_standard_answer": 0 - }, - { - "answer_content": "此恨绵绵无绝期", - "is_standard_answer": 1 - }, - { - "answer_content": "夜半无人私语时", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“人生自古谁无死,留取丹心照汗青”,汗青指什么?", - "type": { - "person": "文天祥", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "皇帝", - "is_standard_answer": 0 - }, - { - "answer_content": "史册", - "is_standard_answer": 1 - }, - { - "answer_content": "大地", - "is_standard_answer": 0 - }, - { - "answer_content": "青草", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,多少楼台烟雨中", - "type": { - "person": "杜牧", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "南朝三百八十寺", - "is_standard_answer": 0 - }, - { - "answer_content": "南朝四百四十寺", - "is_standard_answer": 0 - }, - { - "answer_content": "南朝四百八十寺", - "is_standard_answer": 1 - }, - { - "answer_content": "南朝八百八十寺", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "曲径通幽处,“_________”", - "type": { - "person": "常建 ", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "禅房花木深", - "is_standard_answer": 1 - }, - { - "answer_content": "恨别鸟惊心", - "is_standard_answer": 0 - }, - { - "answer_content": "红衣浅复深", - "is_standard_answer": 0 - }, - { - "answer_content": "城春草木深", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“夕阳无限好,只是近黄昏”是谁写的?", - "type": { - "person": "李商隐", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李商隐", - "is_standard_answer": 1 - }, - { - "answer_content": "白居易", - "is_standard_answer": 0 - }, - { - "answer_content": "杜甫", - "is_standard_answer": 0 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“凤兮凤兮归故乡,遨游四海求其凰”是谁写的?", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "课外", - "dynasty": "汉朝" - }, - "option_answers": [ - { - "answer_content": "诸葛亮", - "is_standard_answer": 0 - }, - { - "answer_content": "刘备", - "is_standard_answer": 0 - }, - { - "answer_content": "司马相如", - "is_standard_answer": 1 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“凤箫声动,玉壶光转,一夜鱼龙舞”描写的是什么节日?", - "type": { - "person": "辛弃疾 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "中秋", - "is_standard_answer": 0 - }, - { - "answer_content": "七夕", - "is_standard_answer": 0 - }, - { - "answer_content": "除夕", - "is_standard_answer": 0 - }, - { - "answer_content": "元夕", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“马作的卢飞快”中的卢是有名的快马,请问三国时“的卢救主”的故事里救的是谁?", - "type": { - "person": "辛弃疾", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "刘备", - "is_standard_answer": 1 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - }, - { - "answer_content": "孙权", - "is_standard_answer": 0 - }, - { - "answer_content": "赵云", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“一声何满子,双泪落君前”中何满子指的是什么?", - "type": { - "person": "张祜", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "词牌名", - "is_standard_answer": 0 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - }, - { - "answer_content": "曲名", - "is_standard_answer": 1 - }, - { - "answer_content": "刘备", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“秦楼月,年年柳色,霸陵伤别”中霸陵是是的陵墓?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "汉武帝", - "is_standard_answer": 0 - }, - { - "answer_content": "汉文帝", - "is_standard_answer": 1 - }, - { - "answer_content": "唐太宗", - "is_standard_answer": 0 - }, - { - "answer_content": "唐玄宗", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "鸟宿池边树,僧“__”月下门", - "type": { - "person": "贾岛", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "翻", - "is_standard_answer": 0 - }, - { - "answer_content": "推", - "is_standard_answer": 0 - }, - { - "answer_content": "敲", - "is_standard_answer": 1 - }, - { - "answer_content": "关", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“冲天香阵透长安,满城尽带黄金甲”描写的是什么花?", - "type": { - "person": "黄巢", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "桂花", - "is_standard_answer": 0 - }, - { - "answer_content": "菊花", - "is_standard_answer": 1 - }, - { - "answer_content": "芙蓉", - "is_standard_answer": 0 - }, - { - "answer_content": "牡丹", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《望岳》中“岱宗夫如何?”描写的是哪座名山?", - "type": { - "person": "杜甫", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "黄山", - "is_standard_answer": 0 - }, - { - "answer_content": "泰山", - "is_standard_answer": 1 - }, - { - "answer_content": "嵩山", - "is_standard_answer": 0 - }, - { - "answer_content": "华山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“白日依山尽,黄河入海流”是哪位诗人写的?", - "type": { - "person": "王之涣", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - }, - { - "answer_content": "王之涣", - "is_standard_answer": 1 - }, - { - "answer_content": "王翰", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“商女不知亡国恨,隔江犹唱后庭花”,《后庭花》是谁写的?", - "type": { - "person": "杜牧 ", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李隆基", - "is_standard_answer": 0 - }, - { - "answer_content": "杨玉环", - "is_standard_answer": 0 - }, - { - "answer_content": "陈叔宝", - "is_standard_answer": 1 - }, - { - "answer_content": "李煜", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "人生若只如初见,“________”", - "type": { - "person": "纳兰性德", - "type": "婉约", - "grade": "课外", - "dynasty": "清朝" - }, - "option_answers": [ - { - "answer_content": "何如薄幸锦衣郎", - "is_standard_answer": 0 - }, - { - "answer_content": "何事秋风悲画扇", - "is_standard_answer": 1 - }, - { - "answer_content": "比翼连枝当日愿", - "is_standard_answer": 0 - }, - { - "answer_content": "只道当时是寻常", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“无为在岐路,儿女共沾巾”哪个字是错误的?", - "type": { - "person": "王勃", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "沾->粘", - "is_standard_answer": 0 - }, - { - "answer_content": "在->再", - "is_standard_answer": 0 - }, - { - "answer_content": "岐->歧", - "is_standard_answer": 1 - }, - { - "answer_content": "巾->襟", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“天阶夜色凉如水,坐看牵牛织女星”描写的是哪个季节?", - "type": { - "person": "杜牧", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "秋", - "is_standard_answer": 1 - }, - { - "answer_content": "冬", - "is_standard_answer": 0 - }, - { - "answer_content": "春", - "is_standard_answer": 0 - }, - { - "answer_content": "夏", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“安得广厦千万间,大庇天下寒士俱欢颜!”是诗人在哪个季节写的?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "春", - "is_standard_answer": 0 - }, - { - "answer_content": "夏", - "is_standard_answer": 0 - }, - { - "answer_content": "秋", - "is_standard_answer": 1 - }, - { - "answer_content": "冬", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "杜甫的“正是江南好风景,落花时节又逢君”中,这个君的职业是什么?", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "农夫", - "is_standard_answer": 0 - }, - { - "answer_content": "秀才", - "is_standard_answer": 0 - }, - { - "answer_content": "乐师", - "is_standard_answer": 1 - }, - { - "answer_content": "官员", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“暖风熏得游人醉,直把杭州作汴州”,杭州和汴州分别又叫做什么?", - "type": { - "person": "林升", - "type": "江南", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "姑苏、洛阳", - "is_standard_answer": 0 - }, - { - "answer_content": "临安、开封", - "is_standard_answer": 1 - }, - { - "answer_content": "临安、洛阳", - "is_standard_answer": 0 - }, - { - "answer_content": "姑苏、开封", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“飞流直下三千尺,疑是银河落九天”描写的是什么景色?", - "type": { - "person": "李白", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "长江", - "is_standard_answer": 0 - }, - { - "answer_content": "黄河", - "is_standard_answer": 0 - }, - { - "answer_content": "瀑布", - "is_standard_answer": 1 - }, - { - "answer_content": "银河", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“鹅鹅鹅,曲项向天歌”是诗人几岁时写的?", - "type": { - "person": "骆宾王", - "type": "田园", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "7", - "is_standard_answer": 1 - }, - { - "answer_content": "3", - "is_standard_answer": 0 - }, - { - "answer_content": "16", - "is_standard_answer": 0 - }, - { - "answer_content": "5", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“丞相祠堂何处寻,锦官城外柏森森”,锦官城指的是哪里?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "成都", - "is_standard_answer": 1 - }, - { - "answer_content": "汉中", - "is_standard_answer": 0 - }, - { - "answer_content": "长安", - "is_standard_answer": 0 - }, - { - "answer_content": "金陵", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "白头宫女在,闲坐说“__”,", - "type": { - "person": "元稹", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "玄宗", - "is_standard_answer": 1 - }, - { - "answer_content": "高宗", - "is_standard_answer": 0 - }, - { - "answer_content": "太宗", - "is_standard_answer": 0 - }, - { - "answer_content": "太祖", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,山雨欲来风满楼", - "type": { - "person": "许浑", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "行人莫问当年事", - "is_standard_answer": 0 - }, - { - "answer_content": "山外青山楼外楼", - "is_standard_answer": 0 - }, - { - "answer_content": "黑云压城城欲摧", - "is_standard_answer": 0 - }, - { - "answer_content": "溪云初起日沉阁", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "《琵琶行》中,琵琶女告诉白居易她是京城女,请问她住在哪里?", - "type": { - "person": "白居易", - "type": "友情", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "回龙观", - "is_standard_answer": 0 - }, - { - "answer_content": "蘑菇屯", - "is_standard_answer": 0 - }, - { - "answer_content": "蛤蟆陵", - "is_standard_answer": 1 - }, - { - "answer_content": "门头沟", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "宁为百夫长,“________”", - "type": { - "person": "杨炯", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "心中自不平", - "is_standard_answer": 0 - }, - { - "answer_content": "单于夜遁逃", - "is_standard_answer": 0 - }, - { - "answer_content": "胜作一书生", - "is_standard_answer": 1 - }, - { - "answer_content": "将军夜引弓", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "\"________\",西出阳关无故人", - "type": { - "person": "王维", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "劝君更尽一杯酒", - "is_standard_answer": 1 - }, - { - "answer_content": "莫愁前路无知己", - "is_standard_answer": 0 - }, - { - "answer_content": "渭城朝雨浥轻尘", - "is_standard_answer": 0 - }, - { - "answer_content": "劝君更饮一杯酒", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,春风不度玉门关", - "type": { - "person": "王之涣", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "二十四桥明月夜", - "is_standard_answer": 0 - }, - { - "answer_content": "羌笛何须怨杨柳", - "is_standard_answer": 1 - }, - { - "answer_content": "黄河远上白云间", - "is_standard_answer": 0 - }, - { - "answer_content": "黄沙百战穿金甲", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "白日登山望烽火,“________”", - "type": { - "person": "李颀", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "黄昏饮马傍交河", - "is_standard_answer": 1 - }, - { - "answer_content": "黄昏独上海风秋", - "is_standard_answer": 0 - }, - { - "answer_content": "不破楼兰终不还", - "is_standard_answer": 0 - }, - { - "answer_content": "孤城遥望玉门关", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“横看成岭侧成峰,远近高低各不同”描写的是哪座山?", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "泰山", - "is_standard_answer": 0 - }, - { - "answer_content": "黄山", - "is_standard_answer": 0 - }, - { - "answer_content": "庐山", - "is_standard_answer": 1 - }, - { - "answer_content": "华山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "沉舟侧畔千帆过,“________”", - "type": { - "person": "刘禹锡", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "到乡翻似烂柯人", - "is_standard_answer": 0 - }, - { - "answer_content": "病树前头万木春", - "is_standard_answer": 1 - }, - { - "answer_content": "潦倒新停浊酒怀", - "is_standard_answer": 0 - }, - { - "answer_content": "西出阳关无故人", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "此情可待成追忆?“________”", - "type": { - "person": "李商隐", - "type": "婉约", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "拔剑四顾心茫然", - "is_standard_answer": 0 - }, - { - "answer_content": "只是当时已惘然", - "is_standard_answer": 1 - }, - { - "answer_content": "到处相逢是偶然", - "is_standard_answer": 0 - }, - { - "answer_content": "只有相思无尽处", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "天街小雨润如酥,“________”", - "type": { - "person": "韩愈", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "牧童遥指杏花村", - "is_standard_answer": 0 - }, - { - "answer_content": "绝胜烟柳满皇都", - "is_standard_answer": 0 - }, - { - "answer_content": "柳色如今深未深", - "is_standard_answer": 0 - }, - { - "answer_content": "草色遥看近却无", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "花径不曾缘客扫,“________”", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "两山排闼送青来", - "is_standard_answer": 0 - }, - { - "answer_content": "蓬门今始为君开", - "is_standard_answer": 1 - }, - { - "answer_content": "但见群鸥日日来", - "is_standard_answer": 0 - }, - { - "answer_content": "樽酒家贫只旧醅", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "因写了句“红杏枝头春意闹”而被称为“红杏尚书”的宋代诗人是谁?", - "type": { - "person": "宋祁", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "宋祁", - "is_standard_answer": 1 - }, - { - "answer_content": "秦观", - "is_standard_answer": 0 - }, - { - "answer_content": "王安石", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《蜀道难》的最后一句?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "侧身西望常咨嗟", - "is_standard_answer": 1 - }, - { - "answer_content": "难于上青天", - "is_standard_answer": 0 - }, - { - "answer_content": "不如早还家", - "is_standard_answer": 0 - }, - { - "answer_content": "嗟尔远道之人胡为乎来哉", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "传说因为公主和李白成为情敌而不相往来,被称作诗佛的人是谁?", - "type": { - "person": "王维", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王维", - "is_standard_answer": 1 - }, - { - "answer_content": "白居易", - "is_standard_answer": 0 - }, - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“碧玉妆成一树高,万条缍下绿丝绦”,哪个字是错的", - "type": { - "person": "贺知章", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "缍->垂", - "is_standard_answer": 1 - }, - { - "answer_content": "妆->庄", - "is_standard_answer": 0 - }, - { - "answer_content": "高->蒿", - "is_standard_answer": 0 - }, - { - "answer_content": "绦->綯", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "黄河远上白云间,“________”", - "type": { - "person": "王之涣", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "将登太行雪满山", - "is_standard_answer": 0 - }, - { - "answer_content": "春风不度玉门关", - "is_standard_answer": 0 - }, - { - "answer_content": "千里江陵一日还", - "is_standard_answer": 0 - }, - { - "answer_content": "一片孤城万仞山", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "黄四娘家花满“__”,千朵万朵压枝低", - "type": { - "person": "杜甫", - "type": "田园", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "稀", - "is_standard_answer": 0 - }, - { - "answer_content": "溪", - "is_standard_answer": 0 - }, - { - "answer_content": "蹊", - "is_standard_answer": 1 - }, - { - "answer_content": "栖", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“千古江山,英雄无觅孙仲谋处”,孙仲谋是谁?", - "type": { - "person": "辛弃疾", - "type": "豪放", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "孙匡", - "is_standard_answer": 0 - }, - { - "answer_content": "孙策", - "is_standard_answer": 0 - }, - { - "answer_content": "孙权", - "is_standard_answer": 1 - }, - { - "answer_content": "孙坚", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "随意春“___”歇,王孙自可留", - "type": { - "person": "王维", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "风", - "is_standard_answer": 0 - }, - { - "answer_content": "水", - "is_standard_answer": 0 - }, - { - "answer_content": "花", - "is_standard_answer": 0 - }, - { - "answer_content": "芳", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“只恐夜深花睡去,故烧高烛照红妆”,诗人是担心哪个花睡了?", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "芍药", - "is_standard_answer": 0 - }, - { - "answer_content": "牡丹", - "is_standard_answer": 0 - }, - { - "answer_content": "海棠", - "is_standard_answer": 1 - }, - { - "answer_content": "荷花", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“_________”,月有阴晴圆缺", - "type": { - "person": "苏轼", - "type": "思乡", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "人有悲欢离合", - "is_standard_answer": 1 - }, - { - "answer_content": "此事古难全", - "is_standard_answer": 0 - }, - { - "answer_content": "但愿人长久", - "is_standard_answer": 0 - }, - { - "answer_content": "今夕是何年", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“师者,所以传道受业解惑也”出自?", - "type": { - "person": "韩愈", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "师说", - "is_standard_answer": 1 - }, - { - "answer_content": "论语", - "is_standard_answer": 0 - }, - { - "answer_content": "中庸", - "is_standard_answer": 0 - }, - { - "answer_content": "大学", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“千门万户曈曈日,总把新桃换旧符”描写的是哪个节日?", - "type": { - "person": "王安石", - "type": "思乡", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "春节", - "is_standard_answer": 1 - }, - { - "answer_content": "元宵节", - "is_standard_answer": 0 - }, - { - "answer_content": "中秋节", - "is_standard_answer": 0 - }, - { - "answer_content": "清明节", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "绿树村边合,“________”", - "type": { - "person": "孟浩然", - "type": "田园", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "青山郭外斜", - "is_standard_answer": 1 - }, - { - "answer_content": "还来就菊花", - "is_standard_answer": 0 - }, - { - "answer_content": "结庐在人境", - "is_standard_answer": 0 - }, - { - "answer_content": "把酒话桑麻", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,清泉石上流", - "type": { - "person": "王维", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "空山新雨后", - "is_standard_answer": 0 - }, - { - "answer_content": "明月几时有", - "is_standard_answer": 0 - }, - { - "answer_content": "明月出天山", - "is_standard_answer": 0 - }, - { - "answer_content": "明月松间照", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“________”,万水千山只等闲", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "小学", - "dynasty": "近现代" - }, - "option_answers": [ - { - "answer_content": "恰同学少年", - "is_standard_answer": 0 - }, - { - "answer_content": "红军不胃远征难", - "is_standard_answer": 0 - }, - { - "answer_content": "红军不怕远征难", - "is_standard_answer": 1 - }, - { - "answer_content": "江山如此多娇", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "以下哪位歌手唱过苏轼的《水调歌头·明月几时有》?", - "type": { - "person": "苏轼", - "type": "思乡", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "刘欢", - "is_standard_answer": 0 - }, - { - "answer_content": "霍尊", - "is_standard_answer": 0 - }, - { - "answer_content": "那英", - "is_standard_answer": 0 - }, - { - "answer_content": "王菲", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "王维观猎时写到“忽过新丰市,还归细柳营”,细柳营是谁屯兵的地方?", - "type": { - "person": "王维", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "周亚夫", - "is_standard_answer": 1 - }, - { - "answer_content": "李广", - "is_standard_answer": 0 - }, - { - "answer_content": "卫青", - "is_standard_answer": 0 - }, - { - "answer_content": "霍去病", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "当年万里觅封侯,匹马戍“___”", - "type": { - "person": "陆游", - "type": "豪放", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "凉州", - "is_standard_answer": 0 - }, - { - "answer_content": "蓟州", - "is_standard_answer": 0 - }, - { - "answer_content": "幽州", - "is_standard_answer": 0 - }, - { - "answer_content": "梁州", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "三杯两盏淡酒,“________”", - "type": { - "person": "李清照", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "雁过也", - "is_standard_answer": 0 - }, - { - "answer_content": "怎敌他晚来风急", - "is_standard_answer": 1 - }, - { - "answer_content": "怎一个愁字了得", - "is_standard_answer": 0 - }, - { - "answer_content": "如今有谁堪摘", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "陆游的《剑门道中遇微雨》中,诗人是怎么过的剑门?", - "type": { - "person": "陆游", - "type": "豪放", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "马车", - "is_standard_answer": 0 - }, - { - "answer_content": "步行", - "is_standard_answer": 0 - }, - { - "answer_content": "骑驴", - "is_standard_answer": 1 - }, - { - "answer_content": "骑马", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“今人不见古时月,今月曾经照古人”是谁写的?", - "type": { - "person": "李白", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "王勃", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“八百里分麾下炙,五十弦翻塞外声”,八百里指的是什么动物?", - "type": { - "person": "辛弃疾", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "驴", - "is_standard_answer": 0 - }, - { - "answer_content": "羊", - "is_standard_answer": 0 - }, - { - "answer_content": "马", - "is_standard_answer": 0 - }, - { - "answer_content": "牛", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "停车坐爱枫林晚,霜叶红于二月花中“坐”是什么意思", - "type": { - "person": "杜牧", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "躺着", - "is_standard_answer": 0 - }, - { - "answer_content": "连坐", - "is_standard_answer": 0 - }, - { - "answer_content": "坐下", - "is_standard_answer": 0 - }, - { - "answer_content": "因为", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "欲把西湖比西子,“________”", - "type": { - "person": "苏轼", - "type": "江南", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "淡妆浓抹总相宜", - "is_standard_answer": 1 - }, - { - "answer_content": "拄杖无时夜叩门", - "is_standard_answer": 0 - }, - { - "answer_content": "山色空蒙雨亦奇", - "is_standard_answer": 0 - }, - { - "answer_content": "门前流水尚能西", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "去年今日此门中,“________”", - "type": { - "person": "崔护", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "人面不知何处去", - "is_standard_answer": 0 - }, - { - "answer_content": "桃花依旧笑春风", - "is_standard_answer": 0 - }, - { - "answer_content": "人面桃花相映红", - "is_standard_answer": 1 - }, - { - "answer_content": "微雨燕双飞", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《石壕吏》中,诗人看到“有吏夜捉人”,谁翻墙走了?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "小儿", - "is_standard_answer": 0 - }, - { - "answer_content": "老妇", - "is_standard_answer": 0 - }, - { - "answer_content": "老翁", - "is_standard_answer": 1 - }, - { - "answer_content": "大儿", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“曲有误,周郎顾”,周郎是谁?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "课外", - "dynasty": "三国" - }, - "option_answers": [ - { - "answer_content": "周瑜", - "is_standard_answer": 1 - }, - { - "answer_content": "文王", - "is_standard_answer": 0 - }, - { - "answer_content": "周公", - "is_standard_answer": 0 - }, - { - "answer_content": "庄周", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,月是故乡明", - "type": { - "person": "杜甫", - "type": "思乡", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "小时不识月", - "is_standard_answer": 0 - }, - { - "answer_content": "露从今夜白", - "is_standard_answer": 1 - }, - { - "answer_content": "人是故乡亲", - "is_standard_answer": 0 - }, - { - "answer_content": "对此空长吟", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“问世间,情为何物,直教生死相许”是谁写的?", - "type": { - "person": "元好问", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "元好问", - "is_standard_answer": 1 - }, - { - "answer_content": "李莫愁", - "is_standard_answer": 0 - }, - { - "answer_content": "金庸", - "is_standard_answer": 0 - }, - { - "answer_content": "古龙", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“东风不与周郎便,铜雀春深锁二乔”中东风指的哪个历史典故?", - "type": { - "person": "杜牧", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "苦肉计", - "is_standard_answer": 0 - }, - { - "answer_content": "草船借箭", - "is_standard_answer": 0 - }, - { - "answer_content": "蒋干盗书", - "is_standard_answer": 0 - }, - { - "answer_content": "火烧赤壁", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "黄沙百战穿金甲,不破“___”终不还", - "type": { - "person": "王昌龄", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "龙城", - "is_standard_answer": 0 - }, - { - "answer_content": "楼兰", - "is_standard_answer": 1 - }, - { - "answer_content": "匈奴", - "is_standard_answer": 0 - }, - { - "answer_content": "单于", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“静女其姝,俟我于城隅。爱而不见,搔首踟蹰”中的“爱”是什么意思?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "高中", - "dynasty": "先秦" - }, - "option_answers": [ - { - "answer_content": "隐藏", - "is_standard_answer": 1 - }, - { - "answer_content": "乐于", - "is_standard_answer": 0 - }, - { - "answer_content": "喜欢", - "is_standard_answer": 0 - }, - { - "answer_content": "因为", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "桃花潭水深千尺,“________”", - "type": { - "person": "李白", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "千里江陵一日还", - "is_standard_answer": 0 - }, - { - "answer_content": "春江水暖鸭先知", - "is_standard_answer": 0 - }, - { - "answer_content": "烟花三月下扬州", - "is_standard_answer": 0 - }, - { - "answer_content": "不及汪伦送我情", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "木欣欣以向荣,“_________”", - "type": { - "person": "陶渊明", - "type": "田园", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "泉涓涓而始流", - "is_standard_answer": 1 - }, - { - "answer_content": "海滔滔以不竭", - "is_standard_answer": 0 - }, - { - "answer_content": "人代代以不息", - "is_standard_answer": 0 - }, - { - "answer_content": "草生生以不息", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "苏轼在《江城子密州出猎》中,左手右手控制的分别是什么动物?", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "马、羊", - "is_standard_answer": 0 - }, - { - "answer_content": "狼、鹰", - "is_standard_answer": 0 - }, - { - "answer_content": "狗、鹰", - "is_standard_answer": 1 - }, - { - "answer_content": "马、鹰", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“孤舟蓑笠翁,独钓寒江雪”是哪位诗人写的?", - "type": { - "person": "柳宗元", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "柳宗元", - "is_standard_answer": 1 - }, - { - "answer_content": "王安石", - "is_standard_answer": 0 - }, - { - "answer_content": "韩愈", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "苏轼的《惠崇江晚景》描写的是一副鸭戏图,你知道这首诗被题在什么地方么?", - "type": { - "person": "苏轼", - "type": "春天", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "画上", - "is_standard_answer": 1 - }, - { - "answer_content": "手帕上", - "is_standard_answer": 0 - }, - { - "answer_content": "扇子上", - "is_standard_answer": 0 - }, - { - "answer_content": "墙上", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“大明湖畔趵突泉边故居在垂杨深处,漱玉集中金石录里文采有后主遗风”指的谁?", - "type": { - "person": "李清照", - "type": "婉约", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "夏雨荷", - "is_standard_answer": 0 - }, - { - "answer_content": "柳如是", - "is_standard_answer": 0 - }, - { - "answer_content": "李清照", - "is_standard_answer": 1 - }, - { - "answer_content": "苏小小", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "移舟泊烟渚,“________”", - "type": { - "person": "孟浩然", - "type": "思乡", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "长河落日圆", - "is_standard_answer": 0 - }, - { - "answer_content": "天气晚来秋", - "is_standard_answer": 0 - }, - { - "answer_content": "日暮客愁新", - "is_standard_answer": 1 - }, - { - "answer_content": "江清月近人", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "一水护田将绿绕,“__”排闼送青来", - "type": { - "person": "王安石", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "一山", - "is_standard_answer": 0 - }, - { - "answer_content": "两岸", - "is_standard_answer": 0 - }, - { - "answer_content": "两山", - "is_standard_answer": 1 - }, - { - "answer_content": "千山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“滚滚长江东逝水,浪花淘尽英雄”最初出自哪里?", - "type": { - "person": "杨慎", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "三国演义", - "is_standard_answer": 0 - }, - { - "answer_content": "水浒传", - "is_standard_answer": 0 - }, - { - "answer_content": "临江仙·滚滚长江东逝水", - "is_standard_answer": 1 - }, - { - "answer_content": "红楼梦", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,恨不相逢未嫁时", - "type": { - "person": "张籍", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "我生君未生", - "is_standard_answer": 0 - }, - { - "answer_content": "人间有味是清欢", - "is_standard_answer": 0 - }, - { - "answer_content": "还君明珠双泪垂", - "is_standard_answer": 1 - }, - { - "answer_content": "公子王孙逐后尘", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "象征陆游和唐婉爱情的那首《钗头凤·红酥手》最初被诗人题在了哪里?", - "type": { - "person": "陆游", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "手帕上", - "is_standard_answer": 0 - }, - { - "answer_content": "画上", - "is_standard_answer": 0 - }, - { - "answer_content": "扇子上", - "is_standard_answer": 0 - }, - { - "answer_content": "墙上", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“清风徐来,水波不兴”描写的是什么地方的景色?", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "西湖", - "is_standard_answer": 0 - }, - { - "answer_content": "秦淮河", - "is_standard_answer": 0 - }, - { - "answer_content": "醉翁亭", - "is_standard_answer": 0 - }, - { - "answer_content": "赤壁", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "山重水复疑无路,“________”", - "type": { - "person": "陆游", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "千里江陵一日还", - "is_standard_answer": 0 - }, - { - "answer_content": "病树前头万木春", - "is_standard_answer": 0 - }, - { - "answer_content": "拄杖无时夜叩门", - "is_standard_answer": 0 - }, - { - "answer_content": "柳暗花明又一村", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“________”,万里长征人未还", - "type": { - "person": "王昌龄", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "一将功成万骨枯", - "is_standard_answer": 0 - }, - { - "answer_content": "醉卧沙场君莫笑", - "is_standard_answer": 0 - }, - { - "answer_content": "秦时明月汉时关", - "is_standard_answer": 1 - }, - { - "answer_content": "千载琵琶作胡语", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "以下诗句出自《声声慢·寻寻觅觅》的是?", - "type": { - "person": "李清照", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "一种相思,两处闲愁", - "is_standard_answer": 0 - }, - { - "answer_content": "至今思项羽,不肯过江东", - "is_standard_answer": 0 - }, - { - "answer_content": "这次第,怎一个愁字了得", - "is_standard_answer": 1 - }, - { - "answer_content": "争渡,争渡,惊起一滩鸥鹭", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“莫笑农家腊酒浑,丰年留客足鸡豚”中豚指的是什么?", - "type": { - "person": "陆游", - "type": "自然", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "河豚", - "is_standard_answer": 0 - }, - { - "answer_content": "海豚", - "is_standard_answer": 0 - }, - { - "answer_content": "鸡肉", - "is_standard_answer": 0 - }, - { - "answer_content": "猪肉", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "黑云压城城欲“__”,甲光向日金鳞开", - "type": { - "person": "李贺", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "摧 ", - "is_standard_answer": 1 - }, - { - "answer_content": "催 ", - "is_standard_answer": 0 - }, - { - "answer_content": "崔", - "is_standard_answer": 0 - }, - { - "answer_content": "推", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“谁家玉笛暗飞声,散入春风满洛城”,洛城指的是哪里?", - "type": { - "person": "李白", - "type": "春天", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "洛阳", - "is_standard_answer": 1 - }, - { - "answer_content": "金陵", - "is_standard_answer": 0 - }, - { - "answer_content": "长安", - "is_standard_answer": 0 - }, - { - "answer_content": "开封", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "洞房昨夜停红烛,“________”", - "type": { - "person": "朱庆馀", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "春宵一刻值千金", - "is_standard_answer": 0 - }, - { - "answer_content": "先遣小姑尝", - "is_standard_answer": 0 - }, - { - "answer_content": "待晓堂前拜舅姑", - "is_standard_answer": 1 - }, - { - "answer_content": "妆罢低声问夫婿", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“昔年有狂客,号尔谪仙人”是在说谁?", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李白", - "is_standard_answer": 1 - }, - { - "answer_content": "白居易", - "is_standard_answer": 0 - }, - { - "answer_content": "杜甫", - "is_standard_answer": 0 - }, - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“莫道不消魂,帘卷西风,人比黄花瘦”作于什么节日?", - "type": { - "person": "李清照", - "type": "婉约", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "重阳节", - "is_standard_answer": 1 - }, - { - "answer_content": "中秋节", - "is_standard_answer": 0 - }, - { - "answer_content": "元宵节", - "is_standard_answer": 0 - }, - { - "answer_content": "清明节", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "海内存知己,“________”", - "type": { - "person": "王勃", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "天涯共此时", - "is_standard_answer": 0 - }, - { - "answer_content": "竟夕起相思", - "is_standard_answer": 0 - }, - { - "answer_content": "儿女共沾巾", - "is_standard_answer": 0 - }, - { - "answer_content": "天涯若比邻", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "旦辞爷娘去,暮宿黄河边,不闻爷娘唤女声,“________”", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "初中", - "dynasty": "南北朝" - }, - "option_answers": [ - { - "answer_content": "木兰不用尚书郎", - "is_standard_answer": 0 - }, - { - "answer_content": "但闻黄河流水鸣溅溅", - "is_standard_answer": 1 - }, - { - "answer_content": "但闻燕山胡骑鸣啾啾", - "is_standard_answer": 0 - }, - { - "answer_content": "唯闻女叹息", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "人生得意须尽欢,“__________”", - "type": { - "person": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "抽刀断水水更流", - "is_standard_answer": 0 - }, - { - "answer_content": "拔剑四顾心茫然", - "is_standard_answer": 0 - }, - { - "answer_content": "会须一饮三百杯", - "is_standard_answer": 0 - }, - { - "answer_content": "莫使金樽空对月", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“________”,千里江陵一日还", - "type": { - "person": "李白", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "孤帆远影碧空尽", - "is_standard_answer": 0 - }, - { - "answer_content": "朝辞白帝彩云间", - "is_standard_answer": 1 - }, - { - "answer_content": "两岸猿声啼不住", - "is_standard_answer": 0 - }, - { - "answer_content": "黄河远上白云间", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“两岸青山相对出,孤帆一片日边来”是诗人李白在什么地方看见的景色", - "type": { - "person": "李白", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "庐山", - "is_standard_answer": 0 - }, - { - "answer_content": "天门山", - "is_standard_answer": 1 - }, - { - "answer_content": "白帝城", - "is_standard_answer": 0 - }, - { - "answer_content": "泰山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "不识庐山真面目,“________”", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "只因身在最高层", - "is_standard_answer": 0 - }, - { - "answer_content": "只缘身在此山中", - "is_standard_answer": 1 - }, - { - "answer_content": "只因身在此山中", - "is_standard_answer": 0 - }, - { - "answer_content": "只缘身在最高层", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "山不在高,有“___”则名", - "type": { - "person": "刘禹锡 ", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "龙", - "is_standard_answer": 0 - }, - { - "answer_content": "汝", - "is_standard_answer": 0 - }, - { - "answer_content": "灵", - "is_standard_answer": 0 - }, - { - "answer_content": "仙", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "岭南非常有名的荔枝“妃子笑”,这个名称和谁有关?", - "type": { - "person": "杜牧", - "type": "婉约", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "杨玉环", - "is_standard_answer": 1 - }, - { - "answer_content": "西施", - "is_standard_answer": 0 - }, - { - "answer_content": "赵飞燕", - "is_standard_answer": 0 - }, - { - "answer_content": "王昭君", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“绿蚁新醅酒,红泥小火炉”最适合什么天气?", - "type": { - "person": "白居易", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "晴天", - "is_standard_answer": 0 - }, - { - "answer_content": "下雪", - "is_standard_answer": 1 - }, - { - "answer_content": "打雷", - "is_standard_answer": 0 - }, - { - "answer_content": "下雨", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“谁念北楼上,临风怀谢公”,谢公是谁?", - "type": { - "person": "李白", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "谢灵运", - "is_standard_answer": 0 - }, - { - "answer_content": "谢玄", - "is_standard_answer": 0 - }, - { - "answer_content": "谢安", - "is_standard_answer": 0 - }, - { - "answer_content": "谢脁", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“_________”,长使英雄泪满襟。", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "出师未捷身先死", - "is_standard_answer": 1 - }, - { - "answer_content": "风萧萧兮易水寒", - "is_standard_answer": 0 - }, - { - "answer_content": "一将功成万骨枯", - "is_standard_answer": 0 - }, - { - "answer_content": "提携玉龙为君死", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“谁言寸草心,报得三春辉”,哪个字是错误的", - "type": { - "person": "孟郊", - "type": "思乡", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "报->抱", - "is_standard_answer": 0 - }, - { - "answer_content": "辉->晖", - "is_standard_answer": 1 - }, - { - "answer_content": "得->的", - "is_standard_answer": 0 - }, - { - "answer_content": "谁->莫", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《兰亭集序》的作者是?", - "type": { - "person": "王羲之", - "type": "友情", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "陈寿", - "is_standard_answer": 0 - }, - { - "answer_content": "陶渊明", - "is_standard_answer": 0 - }, - { - "answer_content": "王羲之", - "is_standard_answer": 1 - }, - { - "answer_content": "刘桢", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“吾爱孟夫子,风流天下闻”中,孟夫子是谁?", - "type": { - "person": "李白", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "孟浩然", - "is_standard_answer": 1 - }, - { - "answer_content": "孟郊", - "is_standard_answer": 0 - }, - { - "answer_content": "孟子", - "is_standard_answer": 0 - }, - { - "answer_content": "老子", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "哪句诗与《滕王阁序》出自同一位诗人?", - "type": { - "person": "王勃", - "type": "友情", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "离离原上草,一岁一枯荣", - "is_standard_answer": 0 - }, - { - "answer_content": "海内存知己,天涯若比邻", - "is_standard_answer": 1 - }, - { - "answer_content": "愿君多采撷,此物最相思", - "is_standard_answer": 0 - }, - { - "answer_content": "春眠不觉晓,处处闻啼鸟", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“斜阳草树,寻常巷陌,人道寄奴曾住”,寄奴和元嘉是什么关系?", - "type": { - "person": "辛弃疾", - "type": "豪放", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "祖孙", - "is_standard_answer": 0 - }, - { - "answer_content": "兄弟", - "is_standard_answer": 0 - }, - { - "answer_content": "父子", - "is_standard_answer": 1 - }, - { - "answer_content": "友人", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "天生丽质难自弃,“________”", - "type": { - "person": "白居易", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "六宫粉黛无颜色", - "is_standard_answer": 0 - }, - { - "answer_content": "始是新承恩泽时", - "is_standard_answer": 0 - }, - { - "answer_content": "一朝选在君王侧", - "is_standard_answer": 1 - }, - { - "answer_content": "养在深闺人未识", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "春风又绿江南岸,“________”", - "type": { - "person": "白居易", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "春来江水绿如蓝", - "is_standard_answer": 0 - }, - { - "answer_content": "钟山只隔数重山", - "is_standard_answer": 0 - }, - { - "answer_content": "明月何时照我还", - "is_standard_answer": 1 - }, - { - "answer_content": "风景旧曾谙", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "下面哪句和“欲把西湖比西子”出自同一首诗", - "type": { - "person": "苏轼", - "type": "江南", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "映日荷花别样红", - "is_standard_answer": 0 - }, - { - "answer_content": "水光潋滟晴方好", - "is_standard_answer": 1 - }, - { - "answer_content": "山外青山楼外楼", - "is_standard_answer": 0 - }, - { - "answer_content": "风光不与四时同", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“青青子衿,悠悠我心”最初出自哪里?", - "type": { - "person": "曹操", - "type": "豪放", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "诗经", - "is_standard_answer": 1 - }, - { - "answer_content": "短歌行", - "is_standard_answer": 0 - }, - { - "answer_content": "孔雀东南飞", - "is_standard_answer": 0 - }, - { - "answer_content": "刘邦", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“梅妻鹤子”指的是谁?", - "type": { - "person": "林逋", - "type": "田园", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王维", - "is_standard_answer": 0 - }, - { - "answer_content": "李煜", - "is_standard_answer": 0 - }, - { - "answer_content": "林逋", - "is_standard_answer": 1 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "渡远荆门外,“________”", - "type": { - "person": "李白", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "月涌大江流", - "is_standard_answer": 0 - }, - { - "answer_content": "江清月近人", - "is_standard_answer": 0 - }, - { - "answer_content": "山色有无中", - "is_standard_answer": 0 - }, - { - "answer_content": "来从楚国游", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“孤篇压全唐”是对哪首诗的评价?", - "type": { - "person": "张若虚", - "type": "春天", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "春江花月夜", - "is_standard_answer": 1 - }, - { - "answer_content": "将进酒", - "is_standard_answer": 0 - }, - { - "answer_content": "长恨歌", - "is_standard_answer": 0 - }, - { - "answer_content": "枫桥夜泊", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "曹操的《短歌行》中写到“周公吐哺天下归心”,周公是谁?", - "type": { - "person": "曹操", - "type": "豪放", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "周公旦", - "is_standard_answer": 1 - }, - { - "answer_content": "刘备", - "is_standard_answer": 0 - }, - { - "answer_content": "刘邦", - "is_standard_answer": 0 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“千里莺啼绿映红,水村山郭酒旗风”出自杜牧的哪首诗?", - "type": { - "person": "杜牧", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "秋夕", - "is_standard_answer": 0 - }, - { - "answer_content": "江南春", - "is_standard_answer": 1 - }, - { - "answer_content": "清明", - "is_standard_answer": 0 - }, - { - "answer_content": "遣怀", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“洛阳亲友若相问,一片冰心在玉壶”,哪个字是错的", - "type": { - "person": "王昌龄", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "在->再", - "is_standard_answer": 0 - }, - { - "answer_content": "若->如", - "is_standard_answer": 1 - }, - { - "answer_content": "洛->安", - "is_standard_answer": 0 - }, - { - "answer_content": "片->篇", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“一年好景君须记”,的下一句中提到了几种颜色?", - "type": { - "person": "苏轼", - "type": "友情", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "2", - "is_standard_answer": 1 - }, - { - "answer_content": "7", - "is_standard_answer": 0 - }, - { - "answer_content": "5", - "is_standard_answer": 0 - }, - { - "answer_content": "4", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“洞房昨夜停红烛”这句诗是写给谁的?", - "type": { - "person": "朱庆馀", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "丈夫", - "is_standard_answer": 0 - }, - { - "answer_content": "妻子", - "is_standard_answer": 0 - }, - { - "answer_content": "考官", - "is_standard_answer": 0 - }, - { - "answer_content": "张籍", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "两岸猿声啼不住,“__”已过万重山", - "type": { - "person": "李白", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "小舟", - "is_standard_answer": 0 - }, - { - "answer_content": "轻舟", - "is_standard_answer": 1 - }, - { - "answer_content": "扁舟", - "is_standard_answer": 0 - }, - { - "answer_content": "青舟", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "山外青山楼外楼,“________”", - "type": { - "person": "林升", - "type": "江南", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "西湖歌舞几时休", - "is_standard_answer": 1 - }, - { - "answer_content": "毕竟西湖六月中", - "is_standard_answer": 0 - }, - { - "answer_content": "直把杭州作汴州", - "is_standard_answer": 0 - }, - { - "answer_content": "风光不与四时同", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "从《送孟浩然之广陵》中,你知道扬州在黄鹤楼哪个方位吗?", - "type": { - "person": "李白", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "南", - "is_standard_answer": 0 - }, - { - "answer_content": "北", - "is_standard_answer": 0 - }, - { - "answer_content": "西", - "is_standard_answer": 0 - }, - { - "answer_content": "东", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "竹外桃花三两枝,春江水暖“__”先知", - "type": { - "person": "苏轼", - "type": "春天", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "羊", - "is_standard_answer": 0 - }, - { - "answer_content": "鸡", - "is_standard_answer": 0 - }, - { - "answer_content": "鸟", - "is_standard_answer": 0 - }, - { - "answer_content": "鸭", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "李白到了黄鹤楼却说出“眼前有景道不得”,以下哪句诗是他看到的?", - "type": { - "person": "崔颢", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "一拳捶碎黄鹤楼", - "is_standard_answer": 0 - }, - { - "answer_content": "眼前有景道不得", - "is_standard_answer": 0 - }, - { - "answer_content": "故人西辞黄鹤楼", - "is_standard_answer": 0 - }, - { - "answer_content": "晴川历历汉阳树", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "红酥手,黄藤酒,“______”", - "type": { - "person": "陆游", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "错错错", - "is_standard_answer": 0 - }, - { - "answer_content": "莫莫莫", - "is_standard_answer": 0 - }, - { - "answer_content": "泪痕红浥鲛绡透", - "is_standard_answer": 0 - }, - { - "answer_content": "满城春色宫墙柳", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“绿杨阴里白沙堤”、“苏堤春晓”都是西湖美景,白堤、苏堤哪个修建的更早?", - "type": { - "person": "白居易", - "type": "江南", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "同时", - "is_standard_answer": 0 - }, - { - "answer_content": "白堤", - "is_standard_answer": 1 - }, - { - "answer_content": "无记载", - "is_standard_answer": 0 - }, - { - "answer_content": "苏堤", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“李白乘舟将欲行,忽闻岸上踏歌声”,唱歌的人当时的职业是什么?", - "type": { - "person": "李白", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "幕僚", - "is_standard_answer": 0 - }, - { - "answer_content": "卸任在家", - "is_standard_answer": 1 - }, - { - "answer_content": "县令", - "is_standard_answer": 0 - }, - { - "answer_content": "琴师", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《扬州慢》中“纵豆蔻词工,青楼梦好,难赋深情”,与哪位诗人有关?", - "type": { - "person": "姜夔 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "柳永", - "is_standard_answer": 0 - }, - { - "answer_content": "李煜", - "is_standard_answer": 0 - }, - { - "answer_content": "李清照", - "is_standard_answer": 0 - }, - { - "answer_content": "杜牧", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "醉卧沙场君莫笑,“________”", - "type": { - "person": "王翰", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "万里长征人未还", - "is_standard_answer": 0 - }, - { - "answer_content": "欲饮琵琶马上催", - "is_standard_answer": 0 - }, - { - "answer_content": "古来征战几人回", - "is_standard_answer": 1 - }, - { - "answer_content": "梦回吹角连营", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《赋得古原草送别》全诗一共几句?", - "type": { - "person": "白居易", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "6", - "is_standard_answer": 0 - }, - { - "answer_content": "8", - "is_standard_answer": 1 - }, - { - "answer_content": "4", - "is_standard_answer": 0 - }, - { - "answer_content": "12", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“但愿人长久,千里共婵娟。”是诗人写给什么人的?", - "type": { - "person": "苏轼", - "type": "思乡", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "妻子", - "is_standard_answer": 0 - }, - { - "answer_content": "父母", - "is_standard_answer": 0 - }, - { - "answer_content": "朋友", - "is_standard_answer": 0 - }, - { - "answer_content": "兄弟", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“功盖三分国,名成八阵图”说的是谁?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "曹操", - "is_standard_answer": 0 - }, - { - "answer_content": "诸葛亮", - "is_standard_answer": 1 - }, - { - "answer_content": "周瑜", - "is_standard_answer": 0 - }, - { - "answer_content": "孙权", - "is_standard_answer": 0 - } - ] - } -] \ No newline at end of file diff --git a/ht/p1/index.php b/ht/p1/index.php deleted file mode 100644 index 6faf0e9..0000000 --- a/ht/p1/index.php +++ /dev/null @@ -1,74 +0,0 @@ - - - - - - - 古诗文答题 - - - -
-
-

📜 古诗文答题

-
- ✓ 答对: 0 - 📝 总题: 0 -
-
- - - -
-
加载中
-
- - - - -
- -
- - - - - - diff --git a/ht/p1/style.css b/ht/p1/style.css deleted file mode 100644 index 0f6c828..0000000 --- a/ht/p1/style.css +++ /dev/null @@ -1,469 +0,0 @@ -:root { - --bg-primary: #f5f0e6; - --bg-card: #fffef9; - --text-primary: #5d4e37; - --text-secondary: #8b7355; - --accent: #c94c4c; - --border: #d4c5a9; - --success: #4a7c59; - --error: #c94c4c; - --shadow: rgba(93, 78, 55, 0.1); -} - -* { - margin: 0; - padding: 0; - box-sizing: border-box; -} - -body { - font-family: 'Microsoft YaHei', 'PingFang SC', sans-serif; - background-color: var(--bg-primary); - color: var(--text-primary); - min-height: 100vh; - padding: 20px; - background-image: - radial-gradient(circle at 20% 80%, rgba(201, 76, 76, 0.05) 0%, transparent 50%), - radial-gradient(circle at 80% 20%, rgba(74, 124, 89, 0.05) 0%, transparent 50%); -} - -.container { - max-width: 600px; - margin: 0 auto; -} - -.header { - text-align: center; - padding: 20px 0; - margin-bottom: 20px; -} - -.header h1 { - font-family: 'KaiTi', 'STKaiti', '楷体', serif; - font-size: 28px; - font-weight: normal; - color: var(--text-primary); - margin-bottom: 8px; - letter-spacing: 4px; -} - -.stats { - display: flex; - justify-content: center; - gap: 20px; - font-size: 14px; - color: var(--text-secondary); -} - -.stats span { - display: flex; - align-items: center; - gap: 4px; -} - -.stats .correct { - color: var(--success); -} - -.navigation { - display: flex; - justify-content: center; - flex-wrap: wrap; - gap: 8px; - margin-bottom: 20px; - padding: 12px; - background: var(--bg-card); - border-radius: 12px; - border: 1px solid var(--border); -} - -.nav-btn { - width: 36px; - height: 36px; - border: 1px solid var(--border); - background: var(--bg-card); - color: var(--text-secondary); - border-radius: 8px; - cursor: pointer; - font-size: 14px; - transition: all 0.3s ease; -} - -.nav-btn:hover { - background: var(--bg-primary); - border-color: var(--accent); - color: var(--accent); -} - -.nav-btn.active { - background: var(--accent); - color: white; - border-color: var(--accent); -} - -.card { - background: var(--bg-card); - border-radius: 16px; - border: 1px solid var(--border); - padding: 30px; - margin-bottom: 20px; - box-shadow: 0 4px 20px var(--shadow); - position: relative; - overflow: hidden; -} - -.card::before { - content: ''; - position: absolute; - top: 0; - left: 0; - right: 0; - height: 4px; - background: linear-gradient(90deg, var(--accent), var(--success)); -} - -.question-number { - position: absolute; - top: 20px; - right: 20px; - font-size: 12px; - color: var(--text-secondary); - background: var(--bg-primary); - padding: 4px 12px; - border-radius: 20px; -} - -.question { - font-family: 'KaiTi', 'STKaiti', '楷体', serif; - font-size: 22px; - line-height: 1.8; - text-align: center; - margin-bottom: 30px; - padding: 20px; - background: linear-gradient(135deg, rgba(212, 197, 169, 0.2), transparent); - border-radius: 12px; - border-left: 3px solid var(--accent); -} - -.options { - display: flex; - flex-direction: column; - gap: 12px; -} - -.option-btn { - display: flex; - align-items: center; - gap: 12px; - padding: 16px 20px; - background: var(--bg-card); - border: 2px solid var(--border); - border-radius: 12px; - cursor: pointer; - transition: all 0.3s ease; - text-align: left; - font-size: 16px; - color: var(--text-primary); -} - -.option-btn:hover { - border-color: var(--accent); - transform: translateX(4px); - box-shadow: 0 2px 10px var(--shadow); -} - -.option-btn.selected { - border-color: var(--accent); - background: rgba(201, 76, 76, 0.05); -} - -.option-btn.correct { - border-color: var(--success); - background: rgba(74, 124, 89, 0.1); -} - -.option-btn.wrong { - border-color: var(--error); - background: rgba(201, 76, 76, 0.1); -} - -.option-num { - width: 28px; - height: 28px; - display: flex; - align-items: center; - justify-content: center; - background: var(--bg-primary); - border-radius: 6px; - font-weight: bold; - font-size: 14px; - color: var(--text-secondary); - flex-shrink: 0; -} - -.option-btn:hover .option-num { - background: var(--accent); - color: white; -} - -.option-btn.selected .option-num { - background: var(--accent); - color: white; -} - -.option-btn.correct .option-num { - background: var(--success); - color: white; -} - -.option-btn.wrong .option-num { - background: var(--error); - color: white; -} - -.hint-btn { - display: flex; - align-items: center; - justify-content: center; - gap: 8px; - margin-top: 20px; - padding: 12px; - background: transparent; - border: 1px dashed var(--border); - border-radius: 12px; - cursor: pointer; - color: var(--text-secondary); - font-size: 14px; - transition: all 0.3s ease; - width: 100%; -} - -.hint-btn:hover { - border-color: var(--accent); - color: var(--accent); - background: rgba(201, 76, 76, 0.05); -} - -.details { - background: var(--bg-card); - border-radius: 12px; - border: 1px solid var(--border); - padding: 20px; - display: grid; - grid-template-columns: repeat(2, 1fr); - gap: 16px; -} - -.detail-item { - text-align: center; - padding: 12px; - background: var(--bg-primary); - border-radius: 8px; -} - -.detail-label { - font-size: 12px; - color: var(--text-secondary); - margin-bottom: 4px; -} - -.detail-value { - font-size: 16px; - color: var(--text-primary); - font-weight: 500; -} - -.feedback { - position: fixed; - top: 50%; - left: 50%; - transform: translate(-50%, -50%) scale(0.8); - background: var(--bg-card); - border-radius: 16px; - padding: 30px 50px; - text-align: center; - box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2); - z-index: 1000; - opacity: 0; - visibility: hidden; - transition: all 0.3s ease; -} - -.feedback.show { - opacity: 1; - visibility: visible; - transform: translate(-50%, -50%) scale(1); -} - -.feedback.correct { - border: 2px solid var(--success); -} - -.feedback.wrong { - border: 2px solid var(--error); -} - -.feedback-icon { - font-size: 48px; - margin-bottom: 12px; -} - -.feedback-text { - font-size: 18px; - color: var(--text-primary); -} - -.overlay { - position: fixed; - top: 0; - left: 0; - right: 0; - bottom: 0; - background: rgba(0, 0, 0, 0.3); - z-index: 999; - opacity: 0; - visibility: hidden; - transition: all 0.3s ease; -} - -.overlay.show { - opacity: 1; - visibility: visible; -} - -.hint-message { - background: var(--bg-card); - border-radius: 12px; - border: 1px solid var(--accent); - padding: 16px; - margin-top: 16px; - font-size: 14px; - color: var(--text-primary); - line-height: 1.6; - display: none; -} - -.hint-message.show { - display: block; - animation: fadeIn 0.3s ease; -} - -.loading { - text-align: center; - padding: 40px; - color: var(--text-secondary); -} - -.loading::after { - content: ''; - display: inline-block; - width: 20px; - height: 20px; - border: 2px solid var(--border); - border-top-color: var(--accent); - border-radius: 50%; - animation: spin 0.8s linear infinite; - margin-left: 10px; - vertical-align: middle; -} - -@keyframes spin { - to { transform: rotate(360deg); } -} - -@keyframes fadeIn { - from { opacity: 0; transform: translateY(-10px); } - to { opacity: 1; transform: translateY(0); } -} - -.error-message { - text-align: center; - padding: 20px; - color: var(--error); -} - -.retry-btn { - display: inline-flex; - align-items: center; - gap: 8px; - margin-top: 12px; - padding: 10px 20px; - background: var(--accent); - color: white; - border: none; - border-radius: 8px; - cursor: pointer; - font-size: 14px; - transition: all 0.3s ease; -} - -.retry-btn:hover { - opacity: 0.9; - transform: translateY(-2px); -} - -.nav-btn.random { - background: linear-gradient(135deg, var(--accent), #e67e22); - color: white; - border: none; - min-width: 60px; -} - -.nav-btn.random:hover { - transform: scale(1.05); - box-shadow: 0 2px 10px rgba(201, 76, 76, 0.3); -} - -.footer { - text-align: center; - padding: 20px; - margin-top: 20px; -} - -.contact-btn { - display: inline-flex; - align-items: center; - gap: 8px; - padding: 12px 24px; - background: linear-gradient(135deg, var(--accent), #e67e22); - color: white; - border: none; - border-radius: 25px; - cursor: pointer; - font-size: 14px; - transition: all 0.3s ease; - text-decoration: none; -} - -.contact-btn:hover { - transform: translateY(-2px); - box-shadow: 0 4px 15px rgba(201, 76, 76, 0.4); -} - -@media (max-width: 480px) { - body { - padding: 12px; - } - - .header h1 { - font-size: 24px; - } - - .card { - padding: 20px; - } - - .question { - font-size: 18px; - padding: 16px; - } - - .details { - grid-template-columns: 1fr 1fr; - gap: 10px; - } - - .detail-item { - padding: 10px; - } -} diff --git a/ht/p1/syx.php b/ht/p1/syx.php deleted file mode 100644 index 3061b14..0000000 --- a/ht/p1/syx.php +++ /dev/null @@ -1,97 +0,0 @@ -1){ -//存在不写入 -}else{ -file_put_contents($json, $a, FILE_APPEND | LOCK_EX);//追加写入,防止同时写入。 -//不存在,继续写入。 -} -}} - -function get_curl($url,$post=0,$referer=1,$cookie=0,$header=0,$ua=0,$nobaody=0){ -$ch = curl_init(); -curl_setopt($ch, CURLOPT_URL,$url); -curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); -curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false); -$httpheader[] = "Accept:application/json"; -$httpheader[] = "Accept-Encoding:gzip,deflate,sdch"; -$httpheader[] = "Accept-Language:zh-CN,zh;q=0.8"; -$httpheader[] = "Connection:close"; -curl_setopt($ch, CURLOPT_HTTPHEADER, $httpheader); -if($post){ -curl_setopt($ch, CURLOPT_POST, 1); -curl_setopt($ch, CURLOPT_POSTFIELDS, $post);} -if($header){ -curl_setopt($ch, CURLOPT_HEADER, TRUE);} -if($cookie){ -curl_setopt($ch, CURLOPT_DICTAPP_MID, $cookie);} -if($referer){ -if($referer==1){ -curl_setopt($ch, CURLOPT_REFERER, 'http://m.qzone.com/infocenter?g_f='); -}else{ -curl_setopt($ch, CURLOPT_REFERER, $referer);}} -if($ua){ -curl_setopt($ch, CURLOPT_USERAGENT,$ua); -}else{ -curl_setopt($ch, CURLOPT_USERAGENT,'Mozilla/5.0 (Linux; U; Android 4.4.1; zh-cn) AppleWebKit/533.1 (KHTML, like Gecko)Version/4.0 MQQBrowser/5.5 Mobile Safari/533.1');} -if($nobaody){ -curl_setopt($ch, CURLOPT_NOBODY,1);} -curl_setopt($ch, CURLOPT_ENCODING, "gzip"); -curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); -$ret = curl_exec($ch); -curl_close($ch); -return $ret;} - -?> \ No newline at end of file diff --git a/ht/reger.php b/ht/reger.php deleted file mode 100644 index a10acef..0000000 --- a/ht/reger.php +++ /dev/null @@ -1,187 +0,0 @@ - - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
-
-

用户注册

- -
- -
-
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- -
-
- - -
-
-
- - - - - diff --git a/ht/style.css b/ht/style.css new file mode 100644 index 0000000..1ca99ce --- /dev/null +++ b/ht/style.css @@ -0,0 +1,545 @@ +:root { + --apple-blue: #007AFF; + --apple-blue-hover: #0056b3; + --apple-green: #34C759; + --apple-red: #FF3B30; + --apple-orange: #FF9500; + --apple-gray: #8E8E93; + --apple-light-gray: #F2F2F7; + --apple-dark-gray: #636366; + --border-radius: 12px; + --border-radius-sm: 8px; + --border-radius-lg: 16px; + --shadow: 0 2px 8px rgba(0, 0, 0, 0.08); + --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.12); + --transition: 0.3s ease; +} + +* { + margin: 0; + padding: 0; + box-sizing: border-box; +} + +body { + font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; + background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); + min-height: 100vh; + padding: 20px; + color: #1d1d1f; +} + +.container { + max-width: 700px; + margin: 0 auto; +} + +.header { + text-align: center; + margin-bottom: 40px; + color: white; +} + +.header h1 { + font-size: 32px; + font-weight: 700; + margin-bottom: 10px; + letter-spacing: -0.5px; +} + +.header p { + font-size: 16px; + opacity: 0.9; +} + +.card { + background: white; + border-radius: var(--border-radius-lg); + box-shadow: var(--shadow); + padding: 40px; + transition: var(--transition); +} + +.card:hover { + box-shadow: var(--shadow-hover); +} + +.form-group { + margin-bottom: 24px; +} + +.form-group label { + display: block; + font-size: 14px; + font-weight: 600; + color: var(--apple-dark-gray); + margin-bottom: 8px; +} + +.form-group label .required { + color: var(--apple-red); + margin-left: 4px; +} + +.form-control { + width: 100%; + padding: 14px 16px; + font-size: 16px; + border: 1px solid #E5E5EA; + border-radius: var(--border-radius-sm); + background: var(--apple-light-gray); + transition: var(--transition); + outline: none; + font-family: inherit; +} + +.form-control:focus { + border-color: var(--apple-blue); + background: white; + box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1); +} + +.form-control::placeholder { + color: var(--apple-gray); +} + +textarea.form-control { + resize: vertical; + min-height: 120px; +} + +select.form-control { + cursor: pointer; + appearance: none; + background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%238E8E93'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E"); + background-repeat: no-repeat; + background-position: right 12px center; + background-size: 20px; + padding-right: 40px; +} + +.btn { + display: inline-flex; + align-items: center; + justify-content: center; + gap: 8px; + padding: 14px 28px; + font-size: 16px; + font-weight: 600; + border: none; + border-radius: var(--border-radius-sm); + cursor: pointer; + transition: var(--transition); + font-family: inherit; +} + +.btn-primary { + background: var(--apple-blue); + color: white; +} + +.btn-primary:hover { + background: var(--apple-blue-hover); + transform: translateY(-1px); +} + +.btn-primary:active { + transform: translateY(0); +} + +.btn-primary:disabled { + background: var(--apple-gray); + cursor: not-allowed; + transform: none; +} + +.btn-secondary { + background: var(--apple-gray); + color: white; + margin-top: 8px; +} + +.btn-secondary:hover { + background: var(--apple-dark-gray); + transform: translateY(-1px); +} + +.btn-secondary:active { + transform: translateY(0); +} + +.btn-block { + width: 100%; +} + +.alert { + padding: 16px 20px; + border-radius: var(--border-radius-sm); + margin-bottom: 24px; + display: none; + align-items: center; + gap: 10px; +} + +.alert.show { + display: flex; +} + +.alert-success { + background: #E8F8ED; + color: var(--apple-green); + border: 1px solid rgba(52, 199, 89, 0.3); +} + +.alert-error { + background: #FCE8E8; + color: var(--apple-red); + border: 1px solid rgba(255, 59, 48, 0.3); +} + +.alert-info { + background: #E8F4FF; + color: var(--apple-blue); + border: 1px solid rgba(0, 122, 255, 0.3); +} + +.debug-section { + margin-top: 30px; + padding: 20px; + background: var(--apple-light-gray); + border-radius: var(--border-radius); +} + +.debug-section h3 { + font-size: 14px; + font-weight: 600; + color: var(--apple-dark-gray); + margin-bottom: 12px; + display: flex; + align-items: center; + gap: 8px; +} + +.debug-btn { + padding: 8px 16px; + font-size: 14px; + background: white; + border: 1px solid #E5E5EA; + border-radius: var(--border-radius-sm); + cursor: pointer; + transition: var(--transition); + margin-right: 8px; + margin-bottom: 8px; +} + +.debug-btn:hover { + background: var(--apple-light-gray); + border-color: var(--apple-gray); +} + +.debug-log { + margin-top: 12px; + padding: 12px; + background: #1d1d1f; + color: #f5f5f7; + border-radius: var(--border-radius-sm); + font-family: 'SF Mono', Monaco, 'Courier New', monospace; + font-size: 13px; + max-height: 200px; + overflow-y: auto; + display: none; +} + +.debug-log.show { + display: block; +} + +.debug-log .log-item { + margin-bottom: 6px; + padding-bottom: 6px; + border-bottom: 1px solid rgba(255, 255, 255, 0.1); +} + +.debug-log .log-item:last-child { + border-bottom: none; + margin-bottom: 0; + padding-bottom: 0; +} + +.debug-log .log-time { + color: var(--apple-gray); + margin-right: 8px; +} + +.loading { + display: none; + width: 20px; + height: 20px; + border: 2px solid rgba(255, 255, 255, 0.3); + border-top-color: white; + border-radius: 50%; + animation: spin 0.8s linear infinite; +} + +.loading.show { + display: inline-block; +} + +@keyframes spin { + to { transform: rotate(360deg); } +} + +.input-wrapper { + position: relative; +} + +.input-wrapper .icon { + position: absolute; + right: 12px; + top: 50%; + transform: translateY(-50%); + font-size: 20px; + display: none; +} + +.input-wrapper .icon.success { + color: var(--apple-green); + display: block; +} + +.input-wrapper .icon.error { + color: var(--apple-red); + display: block; +} + +.form-control.valid { + border-color: var(--apple-green); +} + +.form-control.invalid { + border-color: var(--apple-red); +} + +.modal { + display: none; + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + background: rgba(0, 0, 0, 0.5); + z-index: 1000; + align-items: center; + justify-content: center; + padding: 20px; +} + +.modal.show { + display: flex; + animation: fadeIn 0.3s ease; +} + +@keyframes fadeIn { + from { opacity: 0; } + to { opacity: 1; } +} + +.modal-content { + background: white; + border-radius: var(--border-radius-lg); + box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2); + max-width: 500px; + width: 100%; + animation: slideUp 0.3s ease; +} + +@keyframes slideUp { + from { + transform: translateY(20px); + opacity: 0; + } + to { + transform: translateY(0); + opacity: 1; + } +} + +.modal-header { + padding: 30px 30px 20px; + text-align: center; + border-bottom: 1px solid #E5E5EA; +} + +.modal-header span { + font-size: 64px; + display: block; + margin-bottom: 16px; +} + +.modal-header h2 { + font-size: 24px; + font-weight: 700; + color: var(--apple-dark-gray); + margin: 0; +} + +.modal-body { + padding: 30px; + text-align: center; +} + +.modal-body p { + font-size: 16px; + color: var(--apple-dark-gray); + line-height: 1.6; + margin: 0; +} + +.modal-footer { + padding: 20px 30px 30px; + border-top: 1px solid #E5E5EA; +} + +.modal-footer .btn { + width: 100%; +} + +@media (max-width: 640px) { + body { + padding: 12px; + } + + .card { + padding: 24px; + } + + .header h1 { + font-size: 24px; + } + + .modal-header { + padding: 24px 20px 16px; + } + + .modal-header span { + font-size: 48px; + } + + .modal-header h2 { + font-size: 20px; + } + + .modal-body { + padding: 24px 20px; + } + + .modal-footer { + padding: 16px 20px 24px; + } +} + +.captcha-wrapper { + display: flex; + gap: 12px; + align-items: center; + flex-wrap: wrap; +} + +.captcha-question { + background: linear-gradient(135deg, var(--apple-blue) 0%, #0077ED 100%); + color: white; + padding: 12px 24px; + border-radius: var(--border-radius); + font-size: 18px; + font-weight: 600; + font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; + min-width: 120px; + text-align: center; + user-select: none; +} + +.captcha-input { + flex: 1; + min-width: 150px; +} + +.refresh-btn { + white-space: nowrap; + margin: 0; +} + +.threshold-wrapper { + display: flex; + gap: 12px; + align-items: center; + margin-top: 8px; + flex-wrap: wrap; +} + +.threshold-wrapper label { + font-size: 14px; + font-weight: 500; + color: var(--apple-dark-gray); + white-space: nowrap; +} + +.threshold-input { + width: 100px; +} + +.similarity-info { + margin-top: 12px; +} + +.similarity-item { + padding: 12px 16px; + border-radius: var(--border-radius); + display: flex; + flex-wrap: wrap; + gap: 16px; + align-items: center; +} + +.similarity-item.success { + background: linear-gradient(135deg, #E8F5E9 0%, #C8E6C9 100%); + border: 1px solid #A5D6A7; +} + +.similarity-item.error { + background: linear-gradient(135deg, #FFEBEE 0%, #FFCDD2 100%); + border: 1px solid #EF9A9A; +} + +.similarity-label { + font-weight: 600; + font-size: 14px; +} + +.similarity-item.success .similarity-label { + color: #2E7D32; +} + +.similarity-item.error .similarity-label { + color: #C62828; +} + +.similarity-count, +.similarity-percent { + font-size: 14px; + padding: 4px 12px; + border-radius: 20px; + background: rgba(0, 0, 0, 0.08); + font-weight: 500; +} + +.similarity-item.success .similarity-count, +.similarity-item.success .similarity-percent { + background: rgba(46, 125, 50, 0.15); + color: #2E7D32; +} + +.similarity-item.error .similarity-count, +.similarity-item.error .similarity-percent { + background: rgba(198, 40, 40, 0.15); + color: #C62828; +} diff --git a/ht/tapi.php b/ht/tapi.php deleted file mode 100644 index bbc5d40..0000000 --- a/ht/tapi.php +++ /dev/null @@ -1,287 +0,0 @@ -getOne('users', "username = '$username'"); - - // 验证用户和密码 - if (!$user || !password_verify($password, $user['password'])) { - apiResponse(1, '账号或密码错误'); - } - - // 验证用户状态 - if ($user['status'] != 1) { - apiResponse(1, '账号已被禁用,请联系管理员'); - } - - // 更新最后登录时间 - $db->update('users', [ - 'logtime' => date('Y-m-d H:i:s') - ], "id = {$user['id']}"); - - // 记录登录日志 - writeLog($user['id'], 'login', '用户登录'); - - // 存储session - session_start(); - $_SESSION['user'] = $user; - - // 移除敏感信息 - unset($user['password']); - - apiResponse(0, '登录成功', $user); -} - -/** - * 处理用户注册 - * @param array $params 请求参数 - * @param DB $db 数据库操作对象 - */ -function handleRegister($params, $db) { - // 获取参数 - $username = isset($params['username']) ? safeFilter($params['username']) : ''; - $password = isset($params['password']) ? $params['password'] : ''; - $userIdentifier = isset($params['user_identifier']) ? safeFilter($params['user_identifier']) : ''; - - // 参数验证 - if (empty($username) || empty($password)) { - apiResponse(1, '账号和密码不能为空'); - } - - // 验证账号格式(手机号/邮箱/微信号) - $phoneRegex = '/^1[3456789]\d{9}$/'; - $emailRegex = '/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/'; - $wechatRegex = '/^[a-zA-Z0-9_-]{6,20}$/'; - - if (!preg_match($phoneRegex, $username) && !preg_match($emailRegex, $username) && !preg_match($wechatRegex, $username)) { - apiResponse(1, '请输入正确的手机号、邮箱或微信号'); - } - - // 验证密码长度 - if (strlen($password) < 6) { - apiResponse(1, '密码长度不能少于6位'); - } - - // 检查用户名是否已存在 - $existUser = $db->getOne('users', "username = '$username'"); - if ($existUser) { - apiResponse(1, '该账号已被注册'); - } - - // 密码加密 - $hashedPassword = password_hash($password, PASSWORD_DEFAULT); - - // 添加用户 - $userId = $db->insert('users', [ - 'username' => $username, - 'password' => $hashedPassword, - 'irole' => 0, // 普通用户 - 'status' => 1, // 正常状态 - 'regtime' => date('Y-m-d H:i:s'), - 'user_identifier' => $userIdentifier - ]); - - if (!$userId) { - apiResponse(1, '注册失败,请稍后重试'); - } - - // 记录注册日志 - writeLog($userId, 'register', '用户注册'); - - apiResponse(0, '注册成功'); -} - -/** - * 处理获取用户信息 - * @param array $params 请求参数 - * @param DB $db 数据库操作对象 - */ -function handleGetUserInfo($params, $db) { - // 检查登录状态 - $user = checkLogin(); - if (!$user) { - apiResponse(1, '请先登录'); - } - - // 获取最新的用户信息 - $userInfo = $db->getOne('users', "id = {$user['id']}"); - - if (!$userInfo) { - apiResponse(1, '用户不存在'); - } - - // 移除敏感信息 - unset($userInfo['password']); - - apiResponse(0, '获取成功', $userInfo); -} - -/** - * 处理更新用户标识 - * @param array $params 请求参数 - * @param DB $db 数据库操作对象 - */ -function handleUpdateUserIdentifier($params, $db) { - // 检查登录状态 - $user = checkLogin(); - if (!$user) { - apiResponse(1, '请先登录'); - } - - // 获取参数 - $userIdentifier = isset($params['user_identifier']) ? safeFilter($params['user_identifier']) : ''; - - // 验证用户标识长度 - if (strlen($userIdentifier) > 100) { - apiResponse(1, '用户标识长度不能超过100个字符'); - } - - // 更新用户标识 - $result = $db->update('users', [ - 'user_identifier' => $userIdentifier - ], "id = {$user['id']}"); - - if (!$result) { - apiResponse(1, '更新失败,请稍后重试'); - } - - // 记录日志 - writeLog($user['id'], 'update_identifier', '更新用户标识'); - - // 获取更新后的用户信息 - $updatedUser = $db->getOne('users', "id = {$user['id']}"); - - // 移除敏感信息 - unset($updatedUser['password']); - - // 更新session - session_start(); - $_SESSION['user'] = $updatedUser; - - apiResponse(0, '更新成功', $updatedUser); -} - -/** - * 处理用户登出 - */ -function handleLogout() { - session_start(); - - // 记录登出日志 - if (isset($_SESSION['user']) && !empty($_SESSION['user']['id'])) { - writeLog($_SESSION['user']['id'], 'logout', '用户登出'); - } - - // 清除session - unset($_SESSION['user']); - session_destroy(); - - apiResponse(0, '登出成功'); -} - -/** - * 统一API响应格式 - * @param int $code 状态码,0表示成功,非0表示失败 - * @param string $msg 提示信息 - * @param array $data 返回数据 - */ -function apiResponse($code = 0, $msg = '', $data = []) { - echo json_encode([ - 'code' => $code, - 'msg' => $msg, - 'data' => $data - ], JSON_UNESCAPED_UNICODE); - exit; -} \ No newline at end of file diff --git a/ht/test/API.md b/ht/test/API.md deleted file mode 100644 index 2293dbb..0000000 --- a/ht/test/API.md +++ /dev/null @@ -1,525 +0,0 @@ -# 诗词答题 API 文档 - -## 基础信息 - -| 项目 | 说明 | -|------|------| -| 基础URL | `/api.php` | -| 返回格式 | JSON | -| 编码 | UTF-8 | -| 请求方式 | **GET / POST 都支持** | - -### 请求方式说明 - -| 接口 | 推荐方式 | 原因 | -|------|----------|------| -| 获取题目 (question) | **GET** | 读取操作,简单可缓存 | -| 下一题 (next) | **GET** | 读取操作 | -| 获取新题 (fetch) | **GET** | 读取操作 | -| 提交答案 (answer) | **POST** | 提交操作,更规范 | -| 获取提示 (hint) | **GET** | 读取操作 | -| 题目列表 (list) | **GET** | 读取操作 | -| 刷新缓存 (refresh) | **GET** | 管理操作 | -| 状态统计 (stats) | **GET** | 读取操作 | - -## 通用返回格式 - -```json -{ - "code": 0, - "msg": "", - "data": { ... } -} -``` - -| 字段 | 类型 | 说明 | -|------|------|------| -| code | int | 状态码,0=成功,其他=错误 | -| msg | string | 提示信息 | -| data | object | 返回数据 | - ---- - -## 接口列表 - -### 1. 获取题目 - -**请求** -``` -GET /api.php?action=question&id=0 -``` - -| 参数 | 类型 | 必填 | 说明 | -|------|------|------|------| -| action | string | 否 | 默认为 question | -| id | int | 否 | 题目ID,默认0 | - -**返回** -```json -{ - "code": 0, - "msg": "", - "data": { - "id": 0, - "total": 10, - "question": "欲把西湖比西子,\"________\"", - "author": "苏轼", - "type": "江南", - "grade": "小学", - "dynasty": "宋朝", - "options": [ - {"index": 1, "content": "山色空蒙雨亦奇"}, - {"index": 2, "content": "淡妆浓抹总相宜"}, - {"index": 3, "content": "门前流水尚能西"}, - {"index": 4, "content": "拄杖无时夜叩门"} - ] - } -} -``` - ---- - -### 2. 获取下一题(自动进度) - -**请求** -``` -GET /api.php?action=next -``` - -| 参数 | 类型 | 必填 | 说明 | -|------|------|------|------| -| action | string | 是 | 固定为 next | - -**说明** -- **无需传 id 参数**,系统自动记住当前进度(使用 Session) -- 每次刷新自动跳到下一题 -- 如果已经是最后一题,自动回到第 0 题(循环) - -**使用方式** -| 刷新次数 | 返回的 id | -|----------|-----------| -| 第 1 次 | 1 | -| 第 2 次 | 2 | -| 第 3 次 | 3 | -| ... | ... | -| 第 62 次 | 0 (循环) | - -**返回** -```json -{ - "code": 0, - "msg": "", - "data": { - "id": 1, - "total": 62, - "question": "人生得意须尽欢,\"__________\"", - "author": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝", - "options": [...], - "prev_id": 0 - } -} -``` - ---- - -### 3. 刷新获取新题(推荐) - -**请求** -``` -GET /api.php?action=fetch -``` - -| 参数 | 类型 | 必填 | 说明 | -|------|------|------|------| -| action | string | 是 | 固定为 fetch | - -**说明** -- **每次刷新都从百度 API 获取新题目** -- 新题目自动写入本地缓存(去重) -- 返回本次获取的随机一题 -- API 失败时自动降级使用本地缓存 - -**返回** -```json -{ - "code": 0, - "msg": "", - "data": { - "id": null, - "total": 65, - "question": "人生得意须尽欢,\"__________\"", - "author": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝", - "options": [...], - "from_cache": false, - "new_questions": 3 - } -} -``` - -**额外返回字段** -| 字段 | 类型 | 说明 | -|------|------|------| -| from_cache | bool | 是否来自本地缓存 | -| new_questions | int | 本次新增题目数量 | - ---- - -### 4. 提交答案 - -**请求方式 1:GET(简单)** -``` -GET /api.php?action=answer&id=0&answer=2 -``` - -**请求方式 2:POST(推荐)** -``` -POST /api.php -Content-Type: application/x-www-form-urlencoded - -action=answer&id=0&answer=2 -``` - -或使用 JSON: -``` -POST /api.php -Content-Type: application/json - -{ - "action": "answer", - "id": 0, - "answer": "2" -} -``` - -| 参数 | 类型 | 必填 | 说明 | -|------|------|------|------| -| action | string | 是 | 固定为 answer | -| id | int | 是 | 题目ID | -| answer | string | 是 | 答案序号(1-4) | - -**返回** -```json -{ - "code": 0, - "msg": "", - "data": { - "id": 0, - "correct": true, - "your_answer": "2", - "correct_answer": "2", - "next_id": 1, - "has_next": true - } -} -``` - ---- - -### 5. 获取提示 - -**请求** -``` -GET /api.php?action=hint&id=0 -``` - -| 参数 | 类型 | 必填 | 说明 | -|------|------|------|------| -| action | string | 是 | 固定为 hint | -| id | int | 是 | 题目ID | - -**返回** -```json -{ - "code": 0, - "msg": "", - "data": { - "id": 0, - "hint": "这是首描写江南的诗,你在小学学过它。", - "author": "苏轼", - "dynasty": "宋朝" - } -} -``` - ---- - -### 6. 获取题目列表 - -**请求** -``` -GET /api.php?action=list -``` - -**返回** -```json -{ - "code": 0, - "msg": "", - "data": { - "total": 10, - "list": [ - { - "id": 0, - "question": "欲把西湖比西子,\"________\"...", - "author": "苏轼", - "dynasty": "宋朝" - } - ] - } -} -``` - ---- - -### 7. 刷新缓存 - -**请求** -``` -GET /api.php?action=refresh -``` - -**说明** -- 强制从百度 API 获取最新题目 -- 合并到本地缓存(去重) - -**返回** -```json -{ - "code": 0, - "msg": "", - "data": { - "refreshed": true, - "total": 15 - } -} -``` - ---- - -## 缓存机制 - -| 配置 | 值 | 说明 | -|------|------|------| -| 缓存文件 | `data/questions.json` | 本地JSON文件 | -| 过期时间 | **永不过期** | 永久保存 | -| 去重方式 | 按 `question_content` | 相同题目不重复存储 | -| 降级策略 | API失败自动使用本地缓存 | 原始URL失效也能使用 | -| API 限频 | 5秒内只请求一次 | 防止并发请求百度 | - -### 缓存文件结构 - -```json -{ - "updated": "2024-01-01 12:00:00", - "count": 10, - "questions": [...] -} -``` - ---- - -## 性能优化 - -### 已实现优化 - -| 优化项 | 说明 | -|--------|------| -| 静态变量缓存 | 同一请求内多次读取只加载一次文件 | -| API 请求锁 | 5秒内多人请求只发一次 API | -| 原子写入 | 先写临时文件再 rename,防止数据损坏 | -| 去重优化 | 只在写入时去重,读取时不处理 | -| 超时控制 | API 超时 5 秒,连接超时 3 秒 | - -### 性能预估 - -| 场景 | 响应时间 | -|------|----------| -| 读取本地缓存 | ~2-5ms | -| API 请求成功 | ~200-500ms | -| API 限频降级 | ~1ms(直接读缓存) | -| 100人并发 | 无压力(读缓存为主) | - -### 查看状态 - -``` -GET /api.php?action=stats -``` - -返回: -```json -{ - "code": 0, - "data": { - "total_questions": 149, - "cache_file_size": "40.5 KB", - "last_updated": "2026-03-29 05:04:04", - "memory_usage": "256 KB" - } -} -``` - ---- - -## 错误码 - -| code | 说明 | -|------|------| -| 0 | 成功 | -| 400 | 参数错误 | -| 404 | 题目不存在 | - ---- - -## 使用示例 - -### JavaScript -```javascript -// 获取第一题 -fetch('/api.php?action=question&id=0') - .then(r => r.json()) - .then(d => console.log(d.data.question)); - -// 获取下一题(自动进度,无需传 id) -fetch('/api.php?action=next') - .then(r => r.json()) - .then(d => console.log(d.data.id, d.data.question)); - -// 提交答案 -fetch('/api.php?action=answer&id=0&answer=2') - .then(r => r.json()) - .then(d => { - if(d.data.correct) { - console.log('回答正确!'); - } - }); -``` - -### Flutter/Dart -```dart -import 'package:dio/dio.dart'; - -final dio = Dio(); - -// 获取题目 -Future getQuestion(int id) async { - final res = await dio.get('/api.php', queryParameters: { - 'action': 'question', - 'id': id, - }); - return res.data['data']; -} - -// 获取下一题(自动进度,无需传 id) -Future getNextQuestion() async { - final res = await dio.get('/api.php', queryParameters: { - 'action': 'next', - }); - return res.data['data']; -} - -// 提交答案(POST 方式) -Future checkAnswer(int id, String answer) async { - final res = await dio.post('/api.php', data: { - 'action': 'answer', - 'id': id, - 'answer': answer, - }); - return res.data['data']['correct']; -} -``` - ---- - -## App 集成建议 - -### 方案 1:App 自己管理进度(推荐) - -使用 `?action=question` 接口,App 完全控制进度: - -```dart -class QuizApi { - int _currentId = 0; - int _total = 0; - - Future getQuestion() async { - final res = await dio.get('/api.php', queryParameters: { - 'action': 'question', - 'id': _currentId, - }); - final data = res.data['data']; - _total = data['total'] ?? 0; - return data; - } - - Future submitAnswer(String answer) async { - final res = await dio.post('/api.php', data: { - 'action': 'answer', - 'id': _currentId, - 'answer': answer, - }); - return res.data['data']; - } - - void nextQuestion() { - _currentId++; - if (_currentId >= _total) { - _currentId = 0; - } - } - - int get currentId => _currentId; -} -``` - -**优点**: -- 不依赖 Session,App 完全控制进度 -- 可以随时跳转任意题目 -- 适合多端同步 - ---- - -### 方案 2:使用自动进度 - -使用 `?action=next` 接口,API 自动管理: - -```dart -Future getNextQuestion() async { - final res = await dio.get('/api.php', queryParameters: { - 'action': 'next', - }); - return res.data['data']; -} -``` - -**优点**: -- 简单,无需管理 ID -- 自动循环 - -**缺点**: -- 依赖 Session,需要保持 cookie -- 无法自由跳转题目 - ---- - -### 方案 3:不断获取新题 - -使用 `?action=fetch` 接口,每次都从百度获取新题: - -```dart -Future getNewQuestion() async { - final res = await dio.get('/api.php', queryParameters: { - 'action': 'fetch', - }); - return res.data['data']; -} -``` - -**适用场景**: -- 想要不断扩展题库 -- 用户每次刷新都可能看到新题 diff --git a/ht/test/api.php b/ht/test/api.php deleted file mode 100644 index 8bb3308..0000000 --- a/ht/test/api.php +++ /dev/null @@ -1,353 +0,0 @@ - 0, 'msg' => '', 'data' => null]; - -$action = $_REQUEST['action'] ?? 'question'; -$id = isset($_REQUEST['id']) ? intval($_REQUEST['id']) : null; - -switch($action){ - case 'question': - $result['data'] = getQuestion($id ?? getCurrentId()); - break; - case 'next': - $result['data'] = getNextQuestionAuto(); - break; - case 'fetch': - $result['data'] = fetchNewQuestion(); - break; - case 'answer': - $result['data'] = checkAnswer($id, $_REQUEST['answer'] ?? ''); - break; - case 'hint': - $result['data'] = getHint($id); - break; - case 'list': - $result['data'] = getQuestionList(); - break; - case 'refresh': - $result['data'] = refreshCache(); - break; - case 'stats': - $result['data'] = getStats(); - break; - default: - $result['code'] = 400; - $result['msg'] = '未知操作'; -} - -echo json_encode($result, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT); - -function getStats(){ - global $cacheData; - $cache = loadCache(); - return [ - 'total_questions' => count($cache), - 'cache_file_size' => file_exists(CACHE_FILE) ? round(filesize(CACHE_FILE) / 1024, 2) . ' KB' : 0, - 'last_updated' => file_exists(CACHE_FILE) ? date('Y-m-d H:i:s', filemtime(CACHE_FILE)) : 'N/A', - 'memory_usage' => round(memory_get_peak_usage(true) / 1024, 2) . ' KB' - ]; -} - -function getQuestion($id){ - $cache = loadCache(); - if(empty($cache)){ - return ['error' => '没有题目数据']; - } - if($id < 0 || $id >= count($cache)){ - return ['error' => '题目不存在', 'total' => count($cache)]; - } - $item = $cache[$id]; - return [ - 'id' => $id, - 'total' => count($cache), - 'question' => $item['question_content'], - 'author' => $item['type']['person'] ?? '', - 'type' => $item['type']['type'] ?? '', - 'grade' => $item['type']['grade'] ?? '', - 'dynasty' => $item['type']['dynasty'] ?? '', - 'options' => formatOptions($item['option_answers'] ?? []) - ]; -} - -function getNextQuestionAuto(){ - $cache = loadCache(); - if(empty($cache)){ - return ['error' => '没有题目数据']; - } - $total = count($cache); - $currentId = getCurrentId(); - $nextId = $currentId + 1; - if($nextId >= $total){ - $nextId = 0; - } - setCurrentId($nextId); - $result = getQuestion($nextId); - $result['prev_id'] = $currentId; - return $result; -} - -function getCurrentId(){ - return isset($_SESSION['current_question_id']) ? intval($_SESSION['current_question_id']) : 0; -} - -function setCurrentId($id){ - $_SESSION['current_question_id'] = $id; -} - -function fetchNewQuestion(){ - $apiData = fetchFromBaiduApi(); - - if($apiData === null){ - $cache = loadCache(); - if(!empty($cache)){ - $randomId = array_rand($cache); - $result = formatQuestionItem($randomId, $cache[$randomId], count($cache)); - $result['from_cache'] = true; - $result['api_status'] = 'failed'; - return $result; - } - return ['error' => 'API请求失败且无本地缓存']; - } - - $cache = loadCache(); - $newCount = mergeToCache($apiData, $cache); - - $randomItem = $apiData[array_rand($apiData)]; - $result = formatQuestionItem(null, $randomItem, count($cache)); - $result['from_cache'] = false; - $result['new_questions'] = $newCount; - $result['api_status'] = 'success'; - - return $result; -} - -function formatQuestionItem($id, $item, $total, $fromCache = false, $newCount = 0){ - return [ - 'id' => $id, - 'total' => $total, - 'question' => $item['question_content'], - 'author' => $item['type']['person'] ?? '', - 'type' => $item['type']['type'] ?? '', - 'grade' => $item['type']['grade'] ?? '', - 'dynasty' => $item['type']['dynasty'] ?? '', - 'options' => formatOptions($item['option_answers'] ?? []), - 'from_cache' => $fromCache, - 'new_questions' => $newCount - ]; -} - -function checkAnswer($id, $answer){ - $cache = loadCache(); - if(empty($cache)){ - return ['error' => '没有题目数据']; - } - if($id < 0 || $id >= count($cache)){ - return ['error' => '题目不存在']; - } - $item = $cache[$id]; - $correctAnswer = findAnswer($item['option_answers'] ?? []); - $isCorrect = ($answer === $correctAnswer); - - return [ - 'id' => $id, - 'correct' => $isCorrect, - 'your_answer' => $answer, - 'correct_answer' => $correctAnswer, - 'next_id' => $id + 1, - 'has_next' => $id + 1 < count($cache) - ]; -} - -function getHint($id){ - $cache = loadCache(); - if(empty($cache)){ - return ['error' => '没有题目数据']; - } - if($id < 0 || $id >= count($cache)){ - return ['error' => '题目不存在']; - } - $item = $cache[$id]; - return [ - 'id' => $id, - 'hint' => '这是首描写' . ($item['type']['type'] ?? '') . '的诗,你在' . ($item['type']['grade'] ?? '') . '学过它。', - 'author' => $item['type']['person'] ?? '', - 'dynasty' => $item['type']['dynasty'] ?? '' - ]; -} - -function getQuestionList(){ - $cache = loadCache(); - if(empty($cache)){ - return ['total' => 0, 'list' => []]; - } - $list = []; - foreach($cache as $i => $item){ - $list[] = [ - 'id' => $i, - 'question' => mb_substr($item['question_content'], 0, 30, 'UTF-8') . '...', - 'author' => $item['type']['person'] ?? '', - 'dynasty' => $item['type']['dynasty'] ?? '' - ]; - } - return ['total' => count($list), 'list' => $list]; -} - -function refreshCache(){ - $apiData = fetchFromBaiduApi(); - if($apiData === null){ - return ['refreshed' => false, 'error' => 'API请求失败']; - } - $cache = loadCache(); - $newCount = mergeToCache($apiData, $cache); - return ['refreshed' => true, 'total' => count($cache), 'new_questions' => $newCount]; -} - -function loadCache(){ - global $cacheData; - - if($cacheData !== null){ - return $cacheData; - } - - if(!file_exists(CACHE_FILE)){ - $cacheData = []; - return []; - } - - $content = file_get_contents(CACHE_FILE); - if($content === false){ - $cacheData = []; - return []; - } - - $data = json_decode($content, true); - if(!is_array($data) || !isset($data['questions'])){ - $cacheData = []; - return []; - } - - $cacheData = $data['questions']; - return $cacheData; -} - -function saveCache($questions){ - global $cacheData; - - if(!is_dir(CACHE_DIR)){ - mkdir(CACHE_DIR, 0755, true); - } - - $data = [ - 'updated' => date('Y-m-d H:i:s'), - 'count' => count($questions), - 'questions' => $questions - ]; - - $tempFile = CACHE_FILE . '.tmp'; - $result = file_put_contents($tempFile, json_encode($data, JSON_UNESCAPED_UNICODE), LOCK_EX); - - if($result !== false){ - rename($tempFile, CACHE_FILE); - } - - $cacheData = $questions; -} - -function fetchFromBaiduApi(){ - if(file_exists(API_LOCK_FILE)){ - $lockTime = intval(file_get_contents(API_LOCK_FILE)); - if(time() - $lockTime < API_INTERVAL){ - return null; - } - } - - file_put_contents(API_LOCK_FILE, time()); - - $url = 'https://hanyu.baidu.com/hanyu/ajax/pingce_data'; - $ch = curl_init(); - curl_setopt_array($ch, [ - CURLOPT_URL => $url, - CURLOPT_RETURNTRANSFER => true, - CURLOPT_SSL_VERIFYPEER => false, - CURLOPT_SSL_VERIFYHOST => false, - CURLOPT_TIMEOUT => 5, - CURLOPT_CONNECTTIMEOUT => 3, - CURLOPT_USERAGENT => 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36', - CURLOPT_HTTPHEADER => [ - 'Accept: application/json', - 'Accept-Language: zh-CN,zh;q=0.9' - ] - ]); - $response = curl_exec($ch); - $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); - curl_close($ch); - - if($httpCode !== 200 || empty($response)){ - return null; - } - - $json = json_decode($response, true); - if(!isset($json['data']) || !is_array($json['data'])){ - return null; - } - - return $json['data']; -} - -function mergeToCache($newData, &$existingCache){ - if(empty($newData)){ - return 0; - } - - $existingKeys = []; - foreach($existingCache as $item){ - $key = $item['question_content'] ?? ''; - $existingKeys[$key] = true; - } - - $newCount = 0; - foreach($newData as $item){ - $key = $item['question_content'] ?? ''; - if(!isset($existingKeys[$key])){ - $existingCache[] = $item; - $existingKeys[$key] = true; - $newCount++; - } - } - - if($newCount > 0){ - saveCache($existingCache); - } - - return $newCount; -} - -function formatOptions($options){ - $result = []; - foreach($options as $i => $opt){ - $result[] = [ - 'index' => $i + 1, - 'content' => $opt['answer_content'] ?? '' - ]; - } - return $result; -} - -function findAnswer($options){ - foreach($options as $i => $opt){ - if(($opt['is_standard_answer'] ?? 0) === 1){ - return (string)($i + 1); - } - } - return ''; -} -?> diff --git a/ht/test/data/.htaccess b/ht/test/data/.htaccess deleted file mode 100644 index 36c7a14..0000000 --- a/ht/test/data/.htaccess +++ /dev/null @@ -1,5 +0,0 @@ -order allow,deny -deny from all - - deny from all - diff --git a/ht/test/data/questions.json b/ht/test/data/questions.json deleted file mode 100644 index 028b437..0000000 --- a/ht/test/data/questions.json +++ /dev/null @@ -1,4029 +0,0 @@ -{ - "updated": "2026-03-29 05:04:04", - "count": 149, - "questions": [ - { - "question_content": "小楼昨夜又东风,“_________”", - "type": { - "person": "李煜 ", - "type": "婉约", - "grade": "高中", - "dynasty": "五代" - }, - "option_answers": [ - { - "answer_content": "恰似一春江水项东流", - "is_standard_answer": 0 - }, - { - "answer_content": "恰似故人远来载乡愁", - "is_standard_answer": 0 - }, - { - "answer_content": "珠帘泛婆娑湿衣袖", - "is_standard_answer": 0 - }, - { - "answer_content": "故国不堪回首月明中", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "渡远荆门外,“________”", - "type": { - "person": "李白", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "江清月近人", - "is_standard_answer": 0 - }, - { - "answer_content": "来从楚国游", - "is_standard_answer": 1 - }, - { - "answer_content": "山色有无中", - "is_standard_answer": 0 - }, - { - "answer_content": "月涌大江流", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,崔九堂前几度闻", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "乌衣巷口夕阳斜", - "is_standard_answer": 0 - }, - { - "answer_content": "岐王宅里寻常见", - "is_standard_answer": 1 - }, - { - "answer_content": "正是江南好风景", - "is_standard_answer": 0 - }, - { - "answer_content": "此曲只应天上有", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“无为在岐路,儿女共沾巾”哪个字是错误的?", - "type": { - "person": "王勃", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "巾->襟", - "is_standard_answer": 0 - }, - { - "answer_content": "沾->粘", - "is_standard_answer": 0 - }, - { - "answer_content": "在->再", - "is_standard_answer": 0 - }, - { - "answer_content": "岐->歧", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“白日依山尽,黄河入海流”是哪位诗人写的?", - "type": { - "person": "王之涣", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王翰", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - }, - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "王之涣", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "与“身无彩凤双飞翼,心有灵犀一点通”出自同一首诗的是?", - "type": { - "person": "李商隐", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "昨夜星辰昨夜风", - "is_standard_answer": 1 - }, - { - "answer_content": "青鸟殷勤为探看", - "is_standard_answer": 0 - }, - { - "answer_content": "相见时难别亦难", - "is_standard_answer": 0 - }, - { - "answer_content": "碧海青天夜夜心", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“安得广厦千万间,大庇天下寒士俱欢颜!”是诗人在哪个季节写的?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "夏", - "is_standard_answer": 0 - }, - { - "answer_content": "春", - "is_standard_answer": 0 - }, - { - "answer_content": "秋", - "is_standard_answer": 1 - }, - { - "answer_content": "冬", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“莫道不消魂,帘卷西风,人比黄花瘦”作于什么节日?", - "type": { - "person": "李清照", - "type": "婉约", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "元宵节", - "is_standard_answer": 0 - }, - { - "answer_content": "重阳节", - "is_standard_answer": 1 - }, - { - "answer_content": "清明节", - "is_standard_answer": 0 - }, - { - "answer_content": "中秋节", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“云想衣裳花想容,春风拂槛露华浓”中李白用什么花来描写杨贵妃之美?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "荷花", - "is_standard_answer": 0 - }, - { - "answer_content": "牡丹", - "is_standard_answer": 1 - }, - { - "answer_content": "芍药", - "is_standard_answer": 0 - }, - { - "answer_content": "海棠", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“故人西辞黄鹤楼,烟花三月下扬州”,请问下列哪个代称不是扬州?", - "type": { - "person": "李白", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "江都", - "is_standard_answer": 0 - }, - { - "answer_content": "临安", - "is_standard_answer": 1 - }, - { - "answer_content": "维扬", - "is_standard_answer": 0 - }, - { - "answer_content": "广陵", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "人间“__”芳菲尽,山寺桃花始盛开", - "type": { - "person": "白居易", - "type": "春天", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "六月", - "is_standard_answer": 0 - }, - { - "answer_content": "三月", - "is_standard_answer": 0 - }, - { - "answer_content": "二月", - "is_standard_answer": 0 - }, - { - "answer_content": "四月", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "离离原上草,“________”", - "type": { - "person": "白居易", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "春风吹又生", - "is_standard_answer": 0 - }, - { - "answer_content": "萋萋满别情", - "is_standard_answer": 0 - }, - { - "answer_content": "晴翠接荒城", - "is_standard_answer": 0 - }, - { - "answer_content": "一岁一枯荣", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“________”,恨不相逢未嫁时", - "type": { - "person": "张籍", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "还君明珠双泪垂", - "is_standard_answer": 1 - }, - { - "answer_content": "公子王孙逐后尘", - "is_standard_answer": 0 - }, - { - "answer_content": "我生君未生", - "is_standard_answer": 0 - }, - { - "answer_content": "人间有味是清欢", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "大雨落幽燕,白浪滔天,“________”", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "初中", - "dynasty": "近现代" - }, - "option_answers": [ - { - "answer_content": "知向谁边", - "is_standard_answer": 0 - }, - { - "answer_content": "秦皇岛外打鱼船", - "is_standard_answer": 1 - }, - { - "answer_content": "一片汪洋都不见", - "is_standard_answer": 0 - }, - { - "answer_content": "无限江山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“横看成岭侧成峰,远近高低各不同”描写的是哪座山?", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "庐山", - "is_standard_answer": 1 - }, - { - "answer_content": "泰山", - "is_standard_answer": 0 - }, - { - "answer_content": "黄山", - "is_standard_answer": 0 - }, - { - "answer_content": "华山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《望岳》中“岱宗夫如何?”描写的是哪座名山?", - "type": { - "person": "杜甫", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "泰山", - "is_standard_answer": 1 - }, - { - "answer_content": "华山", - "is_standard_answer": 0 - }, - { - "answer_content": "嵩山", - "is_standard_answer": 0 - }, - { - "answer_content": "黄山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "与“天涯何处无芳草”出自同一首诗的是?", - "type": { - "person": "苏轼", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "墙里秋千墙外道", - "is_standard_answer": 1 - }, - { - "answer_content": "山长水阔知何处", - "is_standard_answer": 0 - }, - { - "answer_content": "衣带渐宽终不悔", - "is_standard_answer": 0 - }, - { - "answer_content": "伫倚危楼风细细", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“不以物喜,不以己悲”出自范仲淹的什么作品?", - "type": { - "person": "范仲淹", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "游钓台记", - "is_standard_answer": 0 - }, - { - "answer_content": "岳阳楼记", - "is_standard_answer": 1 - }, - { - "answer_content": "小石潭记", - "is_standard_answer": 0 - }, - { - "answer_content": "醉翁亭记", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“只恐夜深花睡去,故烧高烛照红妆”,诗人是担心哪个花睡了?", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "牡丹", - "is_standard_answer": 0 - }, - { - "answer_content": "芍药", - "is_standard_answer": 0 - }, - { - "answer_content": "海棠", - "is_standard_answer": 1 - }, - { - "answer_content": "荷花", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《甄嬛传》里安陵容唱的“小山重叠金明灭”中小山指的是什么?", - "type": { - "person": "温庭筠", - "type": "婉约", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "画", - "is_standard_answer": 0 - }, - { - "answer_content": "眉妆", - "is_standard_answer": 1 - }, - { - "answer_content": "小小的山", - "is_standard_answer": 0 - }, - { - "answer_content": "衣服", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "飞流直下三千尺,“____”银河落九天", - "type": { - "person": "李白", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "疑是", - "is_standard_answer": 1 - }, - { - "answer_content": "疑似", - "is_standard_answer": 0 - }, - { - "answer_content": "恰是", - "is_standard_answer": 0 - }, - { - "answer_content": "恰似", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,从此萧郎是路人", - "type": { - "person": "崔郊", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "侯门一入深似海", - "is_standard_answer": 0 - }, - { - "answer_content": "一入侯门深如海", - "is_standard_answer": 0 - }, - { - "answer_content": "一入侯门深似海", - "is_standard_answer": 0 - }, - { - "answer_content": "侯门一入深如海", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "小山重叠金明灭,“_________”", - "type": { - "person": "温庭筠", - "type": "婉约", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "绿杨陌上多离别", - "is_standard_answer": 0 - }, - { - "answer_content": "十二楼中月自明", - "is_standard_answer": 0 - }, - { - "answer_content": "鬓云欲度香腮雪", - "is_standard_answer": 1 - }, - { - "answer_content": "碧天如水夜云轻", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”西北望,射天狼", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "老夫聊发少年狂", - "is_standard_answer": 0 - }, - { - "answer_content": "十年生死两茫茫", - "is_standard_answer": 0 - }, - { - "answer_content": "为报倾城随太守", - "is_standard_answer": 0 - }, - { - "answer_content": "会挽雕弓如满月", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“功盖三分国,名成八阵图”说的是谁?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "诸葛亮", - "is_standard_answer": 1 - }, - { - "answer_content": "孙权", - "is_standard_answer": 0 - }, - { - "answer_content": "周瑜", - "is_standard_answer": 0 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“两岸青山相对出,孤帆一片日边来”是诗人李白在什么地方看见的景色", - "type": { - "person": "李白", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "天门山", - "is_standard_answer": 1 - }, - { - "answer_content": "庐山", - "is_standard_answer": 0 - }, - { - "answer_content": "白帝城", - "is_standard_answer": 0 - }, - { - "answer_content": "泰山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“千里莺啼绿映红,水村山郭酒旗风”出自杜牧的哪首诗?", - "type": { - "person": "杜牧", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "秋夕", - "is_standard_answer": 0 - }, - { - "answer_content": "江南春", - "is_standard_answer": 1 - }, - { - "answer_content": "清明", - "is_standard_answer": 0 - }, - { - "answer_content": "遣怀", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "岭南非常有名的荔枝“妃子笑”,这个名称和谁有关?", - "type": { - "person": "杜牧", - "type": "婉约", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王昭君", - "is_standard_answer": 0 - }, - { - "answer_content": "赵飞燕", - "is_standard_answer": 0 - }, - { - "answer_content": "西施", - "is_standard_answer": 0 - }, - { - "answer_content": "杨玉环", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "因写了句“红杏枝头春意闹”而被称为“红杏尚书”的宋代诗人是谁?", - "type": { - "person": "宋祁", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "秦观", - "is_standard_answer": 0 - }, - { - "answer_content": "宋祁", - "is_standard_answer": 1 - }, - { - "answer_content": "王安石", - "is_standard_answer": 0 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "汉乐府《江南》中鱼戏莲叶东下一句", - "type": { - "person": "苏轼", - "type": "江南", - "grade": "小学", - "dynasty": "汉朝" - }, - "option_answers": [ - { - "answer_content": "鱼戏莲叶西", - "is_standard_answer": 1 - }, - { - "answer_content": "鱼戏莲叶南", - "is_standard_answer": 0 - }, - { - "answer_content": "鱼戏莲叶中", - "is_standard_answer": 0 - }, - { - "answer_content": "鱼戏莲叶北", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "此情可待成追忆?“________”", - "type": { - "person": "李商隐", - "type": "婉约", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "只是当时已惘然", - "is_standard_answer": 1 - }, - { - "answer_content": "到处相逢是偶然", - "is_standard_answer": 0 - }, - { - "answer_content": "拔剑四顾心茫然", - "is_standard_answer": 0 - }, - { - "answer_content": "只有相思无尽处", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "桃花潭水深千尺,“________”", - "type": { - "person": "李白", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "春江水暖鸭先知", - "is_standard_answer": 0 - }, - { - "answer_content": "烟花三月下扬州", - "is_standard_answer": 0 - }, - { - "answer_content": "千里江陵一日还", - "is_standard_answer": 0 - }, - { - "answer_content": "不及汪伦送我情", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“冲天香阵透长安,满城尽带黄金甲”描写的是什么花?", - "type": { - "person": "黄巢", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "牡丹", - "is_standard_answer": 0 - }, - { - "answer_content": "芙蓉", - "is_standard_answer": 0 - }, - { - "answer_content": "菊花", - "is_standard_answer": 1 - }, - { - "answer_content": "桂花", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“执子之手,与子偕老”出自《诗经》,它最初指代的是什么感情?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "先秦" - }, - "option_answers": [ - { - "answer_content": "夫妻情", - "is_standard_answer": 0 - }, - { - "answer_content": "父母情", - "is_standard_answer": 0 - }, - { - "answer_content": "战友情", - "is_standard_answer": 1 - }, - { - "answer_content": "知己情", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“但愿人长久,千里共婵娟。”是诗人写给什么人的?", - "type": { - "person": "苏轼", - "type": "思乡", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "朋友", - "is_standard_answer": 0 - }, - { - "answer_content": "妻子", - "is_standard_answer": 0 - }, - { - "answer_content": "父母", - "is_standard_answer": 0 - }, - { - "answer_content": "兄弟", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“东风不与周郎便,铜雀春深锁二乔”中东风指的哪个历史典故?", - "type": { - "person": "杜牧", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "火烧赤壁", - "is_standard_answer": 1 - }, - { - "answer_content": "蒋干盗书", - "is_standard_answer": 0 - }, - { - "answer_content": "苦肉计", - "is_standard_answer": 0 - }, - { - "answer_content": "草船借箭", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“李白乘舟将欲行,忽闻岸上踏歌声”,唱歌的人当时的职业是什么?", - "type": { - "person": "李白", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "卸任在家", - "is_standard_answer": 1 - }, - { - "answer_content": "琴师", - "is_standard_answer": 0 - }, - { - "answer_content": "县令", - "is_standard_answer": 0 - }, - { - "answer_content": "幕僚", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "黄沙百战穿金甲,不破“___”终不还", - "type": { - "person": "王昌龄", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "匈奴", - "is_standard_answer": 0 - }, - { - "answer_content": "单于", - "is_standard_answer": 0 - }, - { - "answer_content": "龙城", - "is_standard_answer": 0 - }, - { - "answer_content": "楼兰", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "春宵一刻值千金,“________”", - "type": { - "person": "苏轼", - "type": "春天", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "从此君王不早朝", - "is_standard_answer": 0 - }, - { - "answer_content": "赌书消得泼茶香", - "is_standard_answer": 0 - }, - { - "answer_content": "花有清香月有阴", - "is_standard_answer": 1 - }, - { - "answer_content": "待晓堂前拜舅姑", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“__”回首,那人却在,灯火阑珊处。", - "type": { - "person": "辛弃疾 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "默然", - "is_standard_answer": 0 - }, - { - "answer_content": "蓦然", - "is_standard_answer": 1 - }, - { - "answer_content": "幕然", - "is_standard_answer": 0 - }, - { - "answer_content": "墓然", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,月是故乡明", - "type": { - "person": "杜甫", - "type": "思乡", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "人是故乡亲", - "is_standard_answer": 0 - }, - { - "answer_content": "小时不识月", - "is_standard_answer": 0 - }, - { - "answer_content": "对此空长吟", - "is_standard_answer": 0 - }, - { - "answer_content": "露从今夜白", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“清风徐来,水波不兴”描写的是什么地方的景色?", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "赤壁", - "is_standard_answer": 1 - }, - { - "answer_content": "西湖", - "is_standard_answer": 0 - }, - { - "answer_content": "秦淮河", - "is_standard_answer": 0 - }, - { - "answer_content": "醉翁亭", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“朱雀桥边野草花,乌衣巷口夕阳斜”,乌衣巷在哪个城市?", - "type": { - "person": "刘禹锡", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "苏州", - "is_standard_answer": 0 - }, - { - "answer_content": "杭州", - "is_standard_answer": 0 - }, - { - "answer_content": "西安", - "is_standard_answer": 0 - }, - { - "answer_content": "南京", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“知章骑马似乘船,眼花落井水底眠”说的是谁?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王维", - "is_standard_answer": 0 - }, - { - "answer_content": "贺知章", - "is_standard_answer": 1 - }, - { - "answer_content": "杜甫", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《蜀道难》的最后一句?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "侧身西望常咨嗟", - "is_standard_answer": 1 - }, - { - "answer_content": "难于上青天", - "is_standard_answer": 0 - }, - { - "answer_content": "嗟尔远道之人胡为乎来哉", - "is_standard_answer": 0 - }, - { - "answer_content": "不如早还家", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“商女不知亡国恨,隔江犹唱后庭花”,《后庭花》是谁写的?", - "type": { - "person": "杜牧 ", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李隆基", - "is_standard_answer": 0 - }, - { - "answer_content": "陈叔宝", - "is_standard_answer": 1 - }, - { - "answer_content": "李煜", - "is_standard_answer": 0 - }, - { - "answer_content": "杨玉环", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "对名妓薛涛始乱终弃,写出“曾经沧海难为水,除却巫山不是云”的诗人是谁?", - "type": { - "person": "元稹", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "元稹", - "is_standard_answer": 1 - }, - { - "answer_content": "刘禹锡", - "is_standard_answer": 0 - }, - { - "answer_content": "李商隐", - "is_standard_answer": 0 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "明月出天山,“________”", - "type": { - "person": "李白", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "时鸣春涧中", - "is_standard_answer": 0 - }, - { - "answer_content": "清泉石上流", - "is_standard_answer": 0 - }, - { - "answer_content": "呼作白玉盘", - "is_standard_answer": 0 - }, - { - "answer_content": "苍茫云海间", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“惜秦皇汉武,略输文采;唐宗宋祖,稍逊风骚”,秦皇汉武分别指的是谁?", - "type": { - "person": "毛泽东", - "type": "豪放", - "grade": "初中", - "dynasty": "近代" - }, - "option_answers": [ - { - "answer_content": "扶苏、刘秀", - "is_standard_answer": 0 - }, - { - "answer_content": "嬴政、刘彻", - "is_standard_answer": 1 - }, - { - "answer_content": "胡亥、刘备", - "is_standard_answer": 0 - }, - { - "answer_content": "嬴政、刘邦", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "苏轼在《江城子密州出猎》中,左手右手控制的分别是什么动物?", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "狼、鹰", - "is_standard_answer": 0 - }, - { - "answer_content": "狗、鹰", - "is_standard_answer": 1 - }, - { - "answer_content": "马、鹰", - "is_standard_answer": 0 - }, - { - "answer_content": "马、羊", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "哪句诗与《滕王阁序》出自同一位诗人?", - "type": { - "person": "王勃", - "type": "友情", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "愿君多采撷,此物最相思", - "is_standard_answer": 0 - }, - { - "answer_content": "离离原上草,一岁一枯荣", - "is_standard_answer": 0 - }, - { - "answer_content": "春眠不觉晓,处处闻啼鸟", - "is_standard_answer": 0 - }, - { - "answer_content": "海内存知己,天涯若比邻", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "象征陆游和唐婉爱情的那首《钗头凤·红酥手》最初被诗人题在了哪里?", - "type": { - "person": "陆游", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "画上", - "is_standard_answer": 0 - }, - { - "answer_content": "墙上", - "is_standard_answer": 1 - }, - { - "answer_content": "扇子上", - "is_standard_answer": 0 - }, - { - "answer_content": "手帕上", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“丞相祠堂何处寻,锦官城外柏森森”,锦官城指的是哪里?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "成都", - "is_standard_answer": 1 - }, - { - "answer_content": "长安", - "is_standard_answer": 0 - }, - { - "answer_content": "金陵", - "is_standard_answer": 0 - }, - { - "answer_content": "汉中", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“谁家玉笛暗飞声,散入春风满洛城”,洛城指的是哪里?", - "type": { - "person": "李白", - "type": "春天", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "金陵", - "is_standard_answer": 0 - }, - { - "answer_content": "洛阳", - "is_standard_answer": 1 - }, - { - "answer_content": "长安", - "is_standard_answer": 0 - }, - { - "answer_content": "开封", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,多少楼台烟雨中", - "type": { - "person": "杜牧", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "南朝四百八十寺", - "is_standard_answer": 1 - }, - { - "answer_content": "南朝三百八十寺", - "is_standard_answer": 0 - }, - { - "answer_content": "南朝八百八十寺", - "is_standard_answer": 0 - }, - { - "answer_content": "南朝四百四十寺", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "鸟宿池边树,僧“__”月下门", - "type": { - "person": "贾岛", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "敲", - "is_standard_answer": 1 - }, - { - "answer_content": "推", - "is_standard_answer": 0 - }, - { - "answer_content": "关", - "is_standard_answer": 0 - }, - { - "answer_content": "翻", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "山不在高,有“___”则名", - "type": { - "person": "刘禹锡 ", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "灵", - "is_standard_answer": 0 - }, - { - "answer_content": "汝", - "is_standard_answer": 0 - }, - { - "answer_content": "龙", - "is_standard_answer": 0 - }, - { - "answer_content": "仙", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "醉卧沙场君莫笑,“________”", - "type": { - "person": "王翰", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "万里长征人未还", - "is_standard_answer": 0 - }, - { - "answer_content": "梦回吹角连营", - "is_standard_answer": 0 - }, - { - "answer_content": "欲饮琵琶马上催", - "is_standard_answer": 0 - }, - { - "answer_content": "古来征战几人回", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“晴空一鹤排云上,便引诗情到碧霄”描写的是什么季节?", - "type": { - "person": "刘禹锡", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "冬", - "is_standard_answer": 0 - }, - { - "answer_content": "夏", - "is_standard_answer": 0 - }, - { - "answer_content": "秋", - "is_standard_answer": 1 - }, - { - "answer_content": "春", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“相貌丑陋却才华横溢,拒绝徒弟追求,被称作花间词派鼻祖”的是谁?", - "type": { - "person": "温庭筠", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "温庭筠", - "is_standard_answer": 1 - }, - { - "answer_content": "元稹", - "is_standard_answer": 0 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - }, - { - "answer_content": "李煜", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“秦楼月,年年柳色,霸陵伤别”中霸陵是是的陵墓?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "汉武帝", - "is_standard_answer": 0 - }, - { - "answer_content": "唐玄宗", - "is_standard_answer": 0 - }, - { - "answer_content": "唐太宗", - "is_standard_answer": 0 - }, - { - "answer_content": "汉文帝", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "人生得意须尽欢,“__________”", - "type": { - "person": "李白", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "抽刀断水水更流", - "is_standard_answer": 0 - }, - { - "answer_content": "莫使金樽空对月", - "is_standard_answer": 1 - }, - { - "answer_content": "会须一饮三百杯", - "is_standard_answer": 0 - }, - { - "answer_content": "拔剑四顾心茫然", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "欲把西湖比西子,“________”", - "type": { - "person": "苏轼", - "type": "江南", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "拄杖无时夜叩门", - "is_standard_answer": 0 - }, - { - "answer_content": "山色空蒙雨亦奇", - "is_standard_answer": 0 - }, - { - "answer_content": "淡妆浓抹总相宜", - "is_standard_answer": 1 - }, - { - "answer_content": "门前流水尚能西", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,万水千山只等闲", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "小学", - "dynasty": "近现代" - }, - "option_answers": [ - { - "answer_content": "江山如此多娇", - "is_standard_answer": 0 - }, - { - "answer_content": "红军不怕远征难", - "is_standard_answer": 1 - }, - { - "answer_content": "恰同学少年", - "is_standard_answer": 0 - }, - { - "answer_content": "红军不胃远征难", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "八月湖水平,“________”", - "type": { - "person": "孟浩然", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "端居耻圣明", - "is_standard_answer": 0 - }, - { - "answer_content": "清泉石上流", - "is_standard_answer": 0 - }, - { - "answer_content": "涵虚混太清", - "is_standard_answer": 1 - }, - { - "answer_content": "波撼岳阳城", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“松下问童子,言师采药去”,请问是谁在问童子?", - "type": { - "person": "贾岛", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "贺知章", - "is_standard_answer": 0 - }, - { - "answer_content": "松下", - "is_standard_answer": 0 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - }, - { - "answer_content": "贾岛", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“青青子衿,悠悠我心”最初出自哪里?", - "type": { - "person": "曹操", - "type": "豪放", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "刘邦", - "is_standard_answer": 0 - }, - { - "answer_content": "短歌行", - "is_standard_answer": 0 - }, - { - "answer_content": "孔雀东南飞", - "is_standard_answer": 0 - }, - { - "answer_content": "诗经", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "撩乱边愁听不尽,“________”", - "type": { - "person": "王昌龄", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "总是关山旧别情", - "is_standard_answer": 0 - }, - { - "answer_content": "孤城遥望玉门关", - "is_standard_answer": 0 - }, - { - "answer_content": "高高秋月照长城", - "is_standard_answer": 1 - }, - { - "answer_content": "山北山南总是烽", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,千里江陵一日还", - "type": { - "person": "李白", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "两岸猿声啼不住", - "is_standard_answer": 0 - }, - { - "answer_content": "朝辞白帝彩云间", - "is_standard_answer": 1 - }, - { - "answer_content": "黄河远上白云间", - "is_standard_answer": 0 - }, - { - "answer_content": "孤帆远影碧空尽", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "山重水复疑无路,“________”", - "type": { - "person": "陆游", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "病树前头万木春", - "is_standard_answer": 0 - }, - { - "answer_content": "柳暗花明又一村", - "is_standard_answer": 1 - }, - { - "answer_content": "千里江陵一日还", - "is_standard_answer": 0 - }, - { - "answer_content": "拄杖无时夜叩门", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "木欣欣以向荣,“_________”", - "type": { - "person": "陶渊明", - "type": "田园", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "泉涓涓而始流", - "is_standard_answer": 1 - }, - { - "answer_content": "人代代以不息", - "is_standard_answer": 0 - }, - { - "answer_content": "海滔滔以不竭", - "is_standard_answer": 0 - }, - { - "answer_content": "草生生以不息", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "张继那首有名的《枫桥夜泊》中,听到寒山寺的钟声,寒山寺在哪个城市?", - "type": { - "person": "张继", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "杭州", - "is_standard_answer": 0 - }, - { - "answer_content": "扬州", - "is_standard_answer": 0 - }, - { - "answer_content": "苏州", - "is_standard_answer": 1 - }, - { - "answer_content": "临安", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《琵琶行》中,琵琶女告诉白居易她是京城女,请问她住在哪里?", - "type": { - "person": "白居易", - "type": "友情", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "回龙观", - "is_standard_answer": 0 - }, - { - "answer_content": "蘑菇屯", - "is_standard_answer": 0 - }, - { - "answer_content": "蛤蟆陵", - "is_standard_answer": 1 - }, - { - "answer_content": "门头沟", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "写下“两情若是久长时,又岂在朝朝暮暮”,被称作“山抹微云君”的诗人是?", - "type": { - "person": "秦观 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "柳永", - "is_standard_answer": 0 - }, - { - "answer_content": "黄庭坚", - "is_standard_answer": 0 - }, - { - "answer_content": "秦观", - "is_standard_answer": 1 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "苏轼的《惠崇江晚景》描写的是一副鸭戏图,你知道这首诗被题在什么地方么?", - "type": { - "person": "苏轼", - "type": "春天", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "画上", - "is_standard_answer": 1 - }, - { - "answer_content": "扇子上", - "is_standard_answer": 0 - }, - { - "answer_content": "墙上", - "is_standard_answer": 0 - }, - { - "answer_content": "手帕上", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“西出阳关无故人”,阳关在哪个省?", - "type": { - "person": "王维", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "西藏", - "is_standard_answer": 0 - }, - { - "answer_content": "内蒙", - "is_standard_answer": 0 - }, - { - "answer_content": "甘肃", - "is_standard_answer": 1 - }, - { - "answer_content": "新疆", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "花径不曾缘客扫,“________”", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "两山排闼送青来", - "is_standard_answer": 0 - }, - { - "answer_content": "但见群鸥日日来", - "is_standard_answer": 0 - }, - { - "answer_content": "蓬门今始为君开", - "is_standard_answer": 1 - }, - { - "answer_content": "樽酒家贫只旧醅", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "宁为百夫长,“________”", - "type": { - "person": "杨炯", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "胜作一书生", - "is_standard_answer": 1 - }, - { - "answer_content": "将军夜引弓", - "is_standard_answer": 0 - }, - { - "answer_content": "单于夜遁逃", - "is_standard_answer": 0 - }, - { - "answer_content": "心中自不平", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "竹外桃花三两枝,春江水暖“__”先知", - "type": { - "person": "苏轼", - "type": "春天", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "鸡", - "is_standard_answer": 0 - }, - { - "answer_content": "鸭", - "is_standard_answer": 1 - }, - { - "answer_content": "鸟", - "is_standard_answer": 0 - }, - { - "answer_content": "羊", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《兰亭集序》的作者是?", - "type": { - "person": "王羲之", - "type": "友情", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "王羲之", - "is_standard_answer": 1 - }, - { - "answer_content": "刘桢", - "is_standard_answer": 0 - }, - { - "answer_content": "陶渊明", - "is_standard_answer": 0 - }, - { - "answer_content": "陈寿", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“今人不见古时月,今月曾经照古人”是谁写的?", - "type": { - "person": "李白", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 1 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "王勃", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“此地别燕丹,壮士发冲冠”描写的是哪个历史事件?", - "type": { - "person": "骆宾王", - "type": "豪放", - "grade": "课外 ", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "赤壁之战", - "is_standard_answer": 0 - }, - { - "answer_content": "荆轲刺秦", - "is_standard_answer": 1 - }, - { - "answer_content": "巨鹿之战", - "is_standard_answer": 0 - }, - { - "answer_content": "屈原沉江", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“孤篇压全唐”是对哪首诗的评价?", - "type": { - "person": "张若虚", - "type": "春天", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "枫桥夜泊", - "is_standard_answer": 0 - }, - { - "answer_content": "春江花月夜", - "is_standard_answer": 1 - }, - { - "answer_content": "长恨歌", - "is_standard_answer": 0 - }, - { - "answer_content": "将进酒", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“暖风熏得游人醉,直把杭州作汴州”,杭州和汴州分别又叫做什么?", - "type": { - "person": "林升", - "type": "江南", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "姑苏、开封", - "is_standard_answer": 0 - }, - { - "answer_content": "临安、开封", - "is_standard_answer": 1 - }, - { - "answer_content": "临安、洛阳", - "is_standard_answer": 0 - }, - { - "answer_content": "姑苏、洛阳", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "王安石在春节时写的“爆竹声中一岁除,春风送暖入屠苏”中屠苏指的是什么?", - "type": { - "person": "王安石", - "type": "思乡", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "酒", - "is_standard_answer": 1 - }, - { - "answer_content": "祥瑞", - "is_standard_answer": 0 - }, - { - "answer_content": "茶", - "is_standard_answer": 0 - }, - { - "answer_content": "院子", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "此曲只应天上有,人间“__”几回闻", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "哪得", - "is_standard_answer": 0 - }, - { - "answer_content": "只得", - "is_standard_answer": 0 - }, - { - "answer_content": "能得", - "is_standard_answer": 1 - }, - { - "answer_content": "值得", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "王维的“独在异乡为异客,每逢佳节倍思亲”,佳节指的是什么节日?", - "type": { - "person": "王维", - "type": "思乡", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "重阳节", - "is_standard_answer": 1 - }, - { - "answer_content": "端午节", - "is_standard_answer": 0 - }, - { - "answer_content": "元宵节", - "is_standard_answer": 0 - }, - { - "answer_content": "中秋节", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“斜阳草树,寻常巷陌,人道寄奴曾住”,寄奴和元嘉是什么关系?", - "type": { - "person": "辛弃疾", - "type": "豪放", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "友人", - "is_standard_answer": 0 - }, - { - "answer_content": "父子", - "is_standard_answer": 1 - }, - { - "answer_content": "兄弟", - "is_standard_answer": 0 - }, - { - "answer_content": "祖孙", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "洞房昨夜停红烛,“________”", - "type": { - "person": "朱庆馀", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "先遣小姑尝", - "is_standard_answer": 0 - }, - { - "answer_content": "妆罢低声问夫婿", - "is_standard_answer": 0 - }, - { - "answer_content": "春宵一刻值千金", - "is_standard_answer": 0 - }, - { - "answer_content": "待晓堂前拜舅姑", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "沉舟侧畔千帆过,“________”", - "type": { - "person": "刘禹锡", - "type": "友情", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "潦倒新停浊酒怀", - "is_standard_answer": 0 - }, - { - "answer_content": "西出阳关无故人", - "is_standard_answer": 0 - }, - { - "answer_content": "病树前头万木春", - "is_standard_answer": 1 - }, - { - "answer_content": "到乡翻似烂柯人", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“葡萄美酒夜光杯,欲饮琵琶马上催”是哪位诗人写的?", - "type": { - "person": "王翰", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李贺", - "is_standard_answer": 0 - }, - { - "answer_content": "王翰", - "is_standard_answer": 1 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“鹅鹅鹅,曲项向天歌”是诗人几岁时写的?", - "type": { - "person": "骆宾王", - "type": "田园", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "7", - "is_standard_answer": 1 - }, - { - "answer_content": "5", - "is_standard_answer": 0 - }, - { - "answer_content": "3", - "is_standard_answer": 0 - }, - { - "answer_content": "16", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "白居易的《长恨歌》最后一句?", - "type": { - "person": "白居易", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "此恨绵绵无绝期", - "is_standard_answer": 1 - }, - { - "answer_content": "一别音容两渺茫", - "is_standard_answer": 0 - }, - { - "answer_content": "夜半无人私语时", - "is_standard_answer": 0 - }, - { - "answer_content": "在地愿为连理枝", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“莫笑农家腊酒浑,丰年留客足鸡豚”中豚指的是什么?", - "type": { - "person": "陆游", - "type": "自然", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "河豚", - "is_standard_answer": 0 - }, - { - "answer_content": "海豚", - "is_standard_answer": 0 - }, - { - "answer_content": "鸡肉", - "is_standard_answer": 0 - }, - { - "answer_content": "猪肉", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "三杯两盏淡酒,“________”", - "type": { - "person": "李清照", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "如今有谁堪摘", - "is_standard_answer": 0 - }, - { - "answer_content": "怎一个愁字了得", - "is_standard_answer": 0 - }, - { - "answer_content": "怎敌他晚来风急", - "is_standard_answer": 1 - }, - { - "answer_content": "雁过也", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“凤箫声动,玉壶光转,一夜鱼龙舞”描写的是什么节日?", - "type": { - "person": "辛弃疾 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "七夕", - "is_standard_answer": 0 - }, - { - "answer_content": "除夕", - "is_standard_answer": 0 - }, - { - "answer_content": "中秋", - "is_standard_answer": 0 - }, - { - "answer_content": "元夕", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“天阶夜色凉如水,坐看牵牛织女星”描写的是哪个季节?", - "type": { - "person": "杜牧", - "type": "自然", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "夏", - "is_standard_answer": 0 - }, - { - "answer_content": "冬", - "is_standard_answer": 0 - }, - { - "answer_content": "秋", - "is_standard_answer": 1 - }, - { - "answer_content": "春", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "白居易说“江南好,风景旧曾谙”,你知道白居易最忆的是江南哪里么?", - "type": { - "person": "白居易", - "type": "江南", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "杭州", - "is_standard_answer": 1 - }, - { - "answer_content": "姑苏", - "is_standard_answer": 0 - }, - { - "answer_content": "吴宫", - "is_standard_answer": 0 - }, - { - "answer_content": "扬州", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“借问汉宫谁得似,可怜飞燕倚新妆”,这个和赵飞燕相似的女子是谁?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王昭君", - "is_standard_answer": 0 - }, - { - "answer_content": "杨玉环", - "is_standard_answer": 1 - }, - { - "answer_content": "班婕妤", - "is_standard_answer": 0 - }, - { - "answer_content": "貂蝉", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "漠漠水田飞白鹭,“________”", - "type": { - "person": "王维", - "type": "田园", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "两山排闼送青来", - "is_standard_answer": 0 - }, - { - "answer_content": "桃花流水鳜鱼肥", - "is_standard_answer": 0 - }, - { - "answer_content": "两个黄鹂鸣翠柳", - "is_standard_answer": 0 - }, - { - "answer_content": "阴阴夏木啭黄鹂", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "黄河远上白云间,“________”", - "type": { - "person": "王之涣", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "将登太行雪满山", - "is_standard_answer": 0 - }, - { - "answer_content": "一片孤城万仞山", - "is_standard_answer": 1 - }, - { - "answer_content": "千里江陵一日还", - "is_standard_answer": 0 - }, - { - "answer_content": "春风不度玉门关", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "与《孔雀东南飞》并称“乐府双璧”的是?", - "type": { - "person": "李白", - "type": "豪放", - "grade": "初中", - "dynasty": "南北朝" - }, - "option_answers": [ - { - "answer_content": "蒹葭", - "is_standard_answer": 0 - }, - { - "answer_content": "木兰辞", - "is_standard_answer": 1 - }, - { - "answer_content": "长歌行", - "is_standard_answer": 0 - }, - { - "answer_content": "离骚", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“绿杨阴里白沙堤”、“苏堤春晓”都是西湖美景,白堤、苏堤哪个修建的更早?", - "type": { - "person": "白居易", - "type": "江南", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "无记载", - "is_standard_answer": 0 - }, - { - "answer_content": "苏堤", - "is_standard_answer": 0 - }, - { - "answer_content": "白堤", - "is_standard_answer": 1 - }, - { - "answer_content": "同时", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "杜甫的“正是江南好风景,落花时节又逢君”中,这个君的职业是什么?", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "官员", - "is_standard_answer": 0 - }, - { - "answer_content": "秀才", - "is_standard_answer": 0 - }, - { - "answer_content": "乐师", - "is_standard_answer": 1 - }, - { - "answer_content": "农夫", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "天生丽质难自弃,“________”", - "type": { - "person": "白居易", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "一朝选在君王侧", - "is_standard_answer": 1 - }, - { - "answer_content": "始是新承恩泽时", - "is_standard_answer": 0 - }, - { - "answer_content": "养在深闺人未识", - "is_standard_answer": 0 - }, - { - "answer_content": "六宫粉黛无颜色", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "不识庐山真面目,“________”", - "type": { - "person": "苏轼", - "type": "自然", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "只因身在最高层", - "is_standard_answer": 0 - }, - { - "answer_content": "只因身在此山中", - "is_standard_answer": 0 - }, - { - "answer_content": "只缘身在最高层", - "is_standard_answer": 0 - }, - { - "answer_content": "只缘身在此山中", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“碧玉妆成一树高,万条缍下绿丝绦”,哪个字是错的", - "type": { - "person": "贺知章", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "缍->垂", - "is_standard_answer": 1 - }, - { - "answer_content": "绦->綯", - "is_standard_answer": 0 - }, - { - "answer_content": "高->蒿", - "is_standard_answer": 0 - }, - { - "answer_content": "妆->庄", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“_________”,长使英雄泪满襟。", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "出师未捷身先死", - "is_standard_answer": 1 - }, - { - "answer_content": "提携玉龙为君死", - "is_standard_answer": 0 - }, - { - "answer_content": "一将功成万骨枯", - "is_standard_answer": 0 - }, - { - "answer_content": "风萧萧兮易水寒", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "范仲淹在《江上渔者》中写到最爱什么鱼?", - "type": { - "person": "范仲淹", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "鳜鱼", - "is_standard_answer": 0 - }, - { - "answer_content": "鲈鱼", - "is_standard_answer": 1 - }, - { - "answer_content": "鲤鱼", - "is_standard_answer": 0 - }, - { - "answer_content": "草鱼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "天下才有一石,谁占了八斗?", - "type": { - "person": "谢灵运", - "type": "豪放", - "grade": "课外", - "dynasty": "晋朝" - }, - "option_answers": [ - { - "answer_content": "曹植", - "is_standard_answer": 1 - }, - { - "answer_content": "谢灵运", - "is_standard_answer": 0 - }, - { - "answer_content": "曹丕", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“群山万壑赴荆门,生长明妃尚有村”,明妃指的是?", - "type": { - "person": "杜甫", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "杨玉环", - "is_standard_answer": 0 - }, - { - "answer_content": "赵飞燕", - "is_standard_answer": 0 - }, - { - "answer_content": "王昭君", - "is_standard_answer": 1 - }, - { - "answer_content": "文成公主", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "旧时王谢堂前燕,“_________”", - "type": { - "person": "刘禹锡", - "type": "豪放", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "飞来飞去落谁家", - "is_standard_answer": 0 - }, - { - "answer_content": "更深月色半人家", - "is_standard_answer": 0 - }, - { - "answer_content": "蓬门今始为君开", - "is_standard_answer": 0 - }, - { - "answer_content": "飞入寻常百姓家", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "春眠不觉晓,“________”", - "type": { - "person": "孟浩然", - "type": "春天", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "处处闻啼鸟", - "is_standard_answer": 1 - }, - { - "answer_content": "花落知多少", - "is_standard_answer": 0 - }, - { - "answer_content": "处处蚊子咬", - "is_standard_answer": 0 - }, - { - "answer_content": "润物细无声", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“滚滚长江东逝水,浪花淘尽英雄”最初出自哪里?", - "type": { - "person": "杨慎", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "红楼梦", - "is_standard_answer": 0 - }, - { - "answer_content": "三国演义", - "is_standard_answer": 0 - }, - { - "answer_content": "临江仙·滚滚长江东逝水", - "is_standard_answer": 1 - }, - { - "answer_content": "水浒传", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“昔年有狂客,号尔谪仙人”是在说谁?", - "type": { - "person": "杜甫", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "白居易", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 1 - }, - { - "answer_content": "杜甫", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“但使龙城飞将在,不教胡马度阴山”中飞将指的是谁?", - "type": { - "person": "王昌龄", - "type": "豪放", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "卫青", - "is_standard_answer": 0 - }, - { - "answer_content": "周亚夫", - "is_standard_answer": 0 - }, - { - "answer_content": "霍去病", - "is_standard_answer": 0 - }, - { - "answer_content": "李广", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“________”,时鸣春涧中", - "type": { - "person": "王维", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "空山新雨后", - "is_standard_answer": 0 - }, - { - "answer_content": "夜静春山空", - "is_standard_answer": 0 - }, - { - "answer_content": "明月松间照", - "is_standard_answer": 0 - }, - { - "answer_content": "月出惊山鸟", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "海内存知己,“________”", - "type": { - "person": "王勃", - "type": "友情", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "竟夕起相思", - "is_standard_answer": 0 - }, - { - "answer_content": "天涯若比邻", - "is_standard_answer": 1 - }, - { - "answer_content": "天涯共此时", - "is_standard_answer": 0 - }, - { - "answer_content": "儿女共沾巾", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "一水护田将绿绕,“__”排闼送青来", - "type": { - "person": "王安石", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "两岸", - "is_standard_answer": 0 - }, - { - "answer_content": "千山", - "is_standard_answer": 0 - }, - { - "answer_content": "两山", - "is_standard_answer": 1 - }, - { - "answer_content": "一山", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "绿树村边合,“________”", - "type": { - "person": "孟浩然", - "type": "田园", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "把酒话桑麻", - "is_standard_answer": 0 - }, - { - "answer_content": "还来就菊花", - "is_standard_answer": 0 - }, - { - "answer_content": "结庐在人境", - "is_standard_answer": 0 - }, - { - "answer_content": "青山郭外斜", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "《扬州慢》中“纵豆蔻词工,青楼梦好,难赋深情”,与哪位诗人有关?", - "type": { - "person": "姜夔 ", - "type": "婉约", - "grade": "高中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "李清照", - "is_standard_answer": 0 - }, - { - "answer_content": "杜牧", - "is_standard_answer": 1 - }, - { - "answer_content": "李煜", - "is_standard_answer": 0 - }, - { - "answer_content": "柳永", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“__”一片月,万户捣衣声", - "type": { - "person": "李白", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "天上", - "is_standard_answer": 0 - }, - { - "answer_content": "杭州", - "is_standard_answer": 0 - }, - { - "answer_content": "长安", - "is_standard_answer": 1 - }, - { - "answer_content": "人间", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "关关雎鸠,在河之洲。窈窕淑女,君子“__”。", - "type": { - "person": "李白", - "type": "婉约", - "grade": "初中", - "dynasty": "先秦" - }, - "option_answers": [ - { - "answer_content": "好逑", - "is_standard_answer": 1 - }, - { - "answer_content": "好求", - "is_standard_answer": 0 - }, - { - "answer_content": "好浗", - "is_standard_answer": 0 - }, - { - "answer_content": "好仇", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“马作的卢飞快”中的卢是有名的快马,请问三国时“的卢救主”的故事里救的是谁?", - "type": { - "person": "辛弃疾", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "孙权", - "is_standard_answer": 0 - }, - { - "answer_content": "赵云", - "is_standard_answer": 0 - }, - { - "answer_content": "刘备", - "is_standard_answer": 1 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "王维观猎时写到“忽过新丰市,还归细柳营”,细柳营是谁屯兵的地方?", - "type": { - "person": "王维", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "霍去病", - "is_standard_answer": 0 - }, - { - "answer_content": "卫青", - "is_standard_answer": 0 - }, - { - "answer_content": "周亚夫", - "is_standard_answer": 1 - }, - { - "answer_content": "李广", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“________”,山雨欲来风满楼", - "type": { - "person": "许浑", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "溪云初起日沉阁", - "is_standard_answer": 1 - }, - { - "answer_content": "行人莫问当年事", - "is_standard_answer": 0 - }, - { - "answer_content": "黑云压城城欲摧", - "is_standard_answer": 0 - }, - { - "answer_content": "山外青山楼外楼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "《赋得古原草送别》全诗一共几句?", - "type": { - "person": "白居易", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "12", - "is_standard_answer": 0 - }, - { - "answer_content": "4", - "is_standard_answer": 0 - }, - { - "answer_content": "8", - "is_standard_answer": 1 - }, - { - "answer_content": "6", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“问世间,情为何物,直教生死相许”是谁写的?", - "type": { - "person": "元好问", - "type": "婉约", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "元好问", - "is_standard_answer": 1 - }, - { - "answer_content": "金庸", - "is_standard_answer": 0 - }, - { - "answer_content": "李莫愁", - "is_standard_answer": 0 - }, - { - "answer_content": "古龙", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "\"________\",西出阳关无故人", - "type": { - "person": "王维", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "莫愁前路无知己", - "is_standard_answer": 0 - }, - { - "answer_content": "劝君更饮一杯酒", - "is_standard_answer": 0 - }, - { - "answer_content": "渭城朝雨浥轻尘", - "is_standard_answer": 0 - }, - { - "answer_content": "劝君更尽一杯酒", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“洞房昨夜停红烛”这句诗是写给谁的?", - "type": { - "person": "朱庆馀", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "张籍", - "is_standard_answer": 1 - }, - { - "answer_content": "妻子", - "is_standard_answer": 0 - }, - { - "answer_content": "考官", - "is_standard_answer": 0 - }, - { - "answer_content": "丈夫", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "曹操的《短歌行》中写到“周公吐哺天下归心”,周公是谁?", - "type": { - "person": "曹操", - "type": "豪放", - "grade": "高中", - "dynasty": "魏晋" - }, - "option_answers": [ - { - "answer_content": "周公旦", - "is_standard_answer": 1 - }, - { - "answer_content": "刘备", - "is_standard_answer": 0 - }, - { - "answer_content": "刘邦", - "is_standard_answer": 0 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "辛弃疾的《清平乐·村居》中,小儿在做什么?", - "type": { - "person": "辛弃疾", - "type": "田园", - "grade": "小学", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "钓鱼", - "is_standard_answer": 0 - }, - { - "answer_content": "除豆", - "is_standard_answer": 0 - }, - { - "answer_content": "剥莲蓬", - "is_standard_answer": 1 - }, - { - "answer_content": "织鸡笼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“凤兮凤兮归故乡,遨游四海求其凰”是谁写的?", - "type": { - "person": "苏轼", - "type": "豪放", - "grade": "课外", - "dynasty": "汉朝" - }, - "option_answers": [ - { - "answer_content": "刘备", - "is_standard_answer": 0 - }, - { - "answer_content": "李白", - "is_standard_answer": 0 - }, - { - "answer_content": "司马相如", - "is_standard_answer": 1 - }, - { - "answer_content": "诸葛亮", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "传说因为公主和李白成为情敌而不相往来,被称作诗佛的人是谁?", - "type": { - "person": "王维", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王维", - "is_standard_answer": 1 - }, - { - "answer_content": "孟浩然", - "is_standard_answer": 0 - }, - { - "answer_content": "白居易", - "is_standard_answer": 0 - }, - { - "answer_content": "李贺", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "人生若只如初见,“________”", - "type": { - "person": "纳兰性德", - "type": "婉约", - "grade": "课外", - "dynasty": "清朝" - }, - "option_answers": [ - { - "answer_content": "何事秋风悲画扇", - "is_standard_answer": 1 - }, - { - "answer_content": "比翼连枝当日愿", - "is_standard_answer": 0 - }, - { - "answer_content": "何如薄幸锦衣郎", - "is_standard_answer": 0 - }, - { - "answer_content": "只道当时是寻常", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "曲径通幽处,“_________”", - "type": { - "person": "常建 ", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "禅房花木深", - "is_standard_answer": 1 - }, - { - "answer_content": "红衣浅复深", - "is_standard_answer": 0 - }, - { - "answer_content": "城春草木深", - "is_standard_answer": 0 - }, - { - "answer_content": "恨别鸟惊心", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“二十四桥明月夜,玉人何处教吹箫”是描写的哪个城市?", - "type": { - "person": "杜牧", - "type": "江南", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "苏州", - "is_standard_answer": 0 - }, - { - "answer_content": "南京", - "is_standard_answer": 0 - }, - { - "answer_content": "扬州", - "is_standard_answer": 1 - }, - { - "answer_content": "杭州", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“孤舟蓑笠翁,独钓寒江雪”是哪位诗人写的?", - "type": { - "person": "柳宗元", - "type": "自然", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王安石", - "is_standard_answer": 0 - }, - { - "answer_content": "柳宗元", - "is_standard_answer": 1 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "韩愈", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“八百里分麾下炙,五十弦翻塞外声”,八百里指的是什么动物?", - "type": { - "person": "辛弃疾", - "type": "豪放", - "grade": "初中", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "牛", - "is_standard_answer": 1 - }, - { - "answer_content": "马", - "is_standard_answer": 0 - }, - { - "answer_content": "羊", - "is_standard_answer": 0 - }, - { - "answer_content": "驴", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "行到水穷处,“________”", - "type": { - "person": "王维", - "type": "田园", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "独坐敬亭山", - "is_standard_answer": 0 - }, - { - "answer_content": "谈笑无还期", - "is_standard_answer": 0 - }, - { - "answer_content": "坐看云起时", - "is_standard_answer": 1 - }, - { - "answer_content": "王孙自可留", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "骆宾王的《咏鹅》中,鹅掌是什么颜色的?", - "type": { - "person": "骆宾王", - "type": "友情", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "红", - "is_standard_answer": 1 - }, - { - "answer_content": "绿", - "is_standard_answer": 0 - }, - { - "answer_content": "灰", - "is_standard_answer": 0 - }, - { - "answer_content": "白", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“座中泣下谁最多,江州司马青衫湿”,江州司马是谁?", - "type": { - "person": "白居易", - "type": "豪放", - "grade": "高中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "王维", - "is_standard_answer": 0 - }, - { - "answer_content": "白居易", - "is_standard_answer": 1 - }, - { - "answer_content": "苏轼", - "is_standard_answer": 0 - }, - { - "answer_content": "元稹", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“谁言寸草心,报得三春辉”,哪个字是错误的", - "type": { - "person": "孟郊", - "type": "思乡", - "grade": "小学", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "得->的", - "is_standard_answer": 0 - }, - { - "answer_content": "辉->晖", - "is_standard_answer": 1 - }, - { - "answer_content": "谁->莫", - "is_standard_answer": 0 - }, - { - "answer_content": "报->抱", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“一声何满子,双泪落君前”中何满子指的是什么?", - "type": { - "person": "张祜", - "type": "豪放", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "词牌名", - "is_standard_answer": 0 - }, - { - "answer_content": "曲名", - "is_standard_answer": 1 - }, - { - "answer_content": "曹操", - "is_standard_answer": 0 - }, - { - "answer_content": "刘备", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“看朱成碧思纷纷,憔悴支离为忆君”,这个君指的是谁?", - "type": { - "person": "武则天", - "type": "思乡", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "李世民", - "is_standard_answer": 0 - }, - { - "answer_content": "刘彻", - "is_standard_answer": 0 - }, - { - "answer_content": "李治", - "is_standard_answer": 1 - }, - { - "answer_content": "李隆基", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "李白到了黄鹤楼却说出“眼前有景道不得”,以下哪句诗是他看到的?", - "type": { - "person": "崔颢", - "type": "自然", - "grade": "初中", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "晴川历历汉阳树", - "is_standard_answer": 1 - }, - { - "answer_content": "一拳捶碎黄鹤楼", - "is_standard_answer": 0 - }, - { - "answer_content": "眼前有景道不得", - "is_standard_answer": 0 - }, - { - "answer_content": "故人西辞黄鹤楼", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "去年今日此门中,“________”", - "type": { - "person": "崔护", - "type": "婉约", - "grade": "课外", - "dynasty": "唐朝" - }, - "option_answers": [ - { - "answer_content": "人面不知何处去", - "is_standard_answer": 0 - }, - { - "answer_content": "桃花依旧笑春风", - "is_standard_answer": 0 - }, - { - "answer_content": "微雨燕双飞", - "is_standard_answer": 0 - }, - { - "answer_content": "人面桃花相映红", - "is_standard_answer": 1 - } - ] - }, - { - "question_content": "“一年好景君须记”,的下一句中提到了几种颜色?", - "type": { - "person": "苏轼", - "type": "友情", - "grade": "课外", - "dynasty": "宋朝" - }, - "option_answers": [ - { - "answer_content": "2", - "is_standard_answer": 1 - }, - { - "answer_content": "7", - "is_standard_answer": 0 - }, - { - "answer_content": "5", - "is_standard_answer": 0 - }, - { - "answer_content": "4", - "is_standard_answer": 0 - } - ] - }, - { - "question_content": "“曲有误,周郎顾”,周郎是谁?", - "type": { - "person": "李白", - "type": "婉约", - "grade": "课外", - "dynasty": "三国" - }, - "option_answers": [ - { - "answer_content": "周瑜", - "is_standard_answer": 1 - }, - { - "answer_content": "庄周", - "is_standard_answer": 0 - }, - { - "answer_content": "周公", - "is_standard_answer": 0 - }, - { - "answer_content": "文王", - "is_standard_answer": 0 - } - ] - } - ] -} \ No newline at end of file diff --git a/ht/test/index.html b/ht/test/index.html deleted file mode 100644 index e2149a4..0000000 --- a/ht/test/index.html +++ /dev/null @@ -1,422 +0,0 @@ - - - - - - 诗词答题 API 测试 - - - -
-
-

📚 诗词答题 API 测试

-

测试所有接口功能

-
- -
-
-

🎯 接口测试

- -
- - - - - - -
- -
- - -
- -
- - -
- -
- - -
- -
等待请求...
- -
-
- -
-

📤 响应结果

-
-
-
点击左侧按钮开始测试...
-
-
-
-
- - - - diff --git a/ht/uploads/img_69c3f26541236_20260325.jpg b/ht/uploads/img_69c3f26541236_20260325.jpg deleted file mode 100644 index 066e07e607fbfcf9ce782cac7b496d3bd67e3271..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 46231 zcmeFYWn5g(vM9P>(BP6_g9Jzj?gW?M?gUNH0E4^R5HvUe0>Og21qKZg5(bySg1ft0 zfJe6d_dfTWcklc1KHZw%^wf0K>Z;YNS9f()_5H8=MF3wxMqUO$LIMD!hYxVSjPy%h zQu3{uhN_IblJwsR-M|B&Z~%avy{of^>?;~wJ$)MV#lK(ihh}2t;`rzHe}IQ}&nN!0 z4gjO9{{zqeTQ#P+g^Sq(!{Ni1-uXfJgR;aAII-p5@fUw^)4$`we{c_1N7n})wLiGC zmWJd5ZvKG3u>3dN^xtqZN9RBMQ4c)AcD8PRWc`6Z8e?17YimCIVmy4ofD51j$O5na z-2cP>2XM#%0RA%o0LA@PXPOEC^&tR2I{jB2eKr8#y$1l;&|h_b^@*d2v&r9@LwP8X z-@OBX<3a$y(E|XYVE}k!@Hg5+@jvKB^FRVW=;iS6u>@=Z3xEcY2kZeefb9X}0yqFp zfbV_=kOV-;f8b9EdH@tOls|xhhK7oUiSg(WCI%+vBWyhEM_9O6n3y;OIJkKD_yqWm zunCC>@rfRA{6CE#{kal^g7I)6J{Bg{L+$@ZxNiptFpy=CUxAQl0b~Ls5CPKt4}j`V zccUZy8HxV{BxF=HbPP-o%A*Im8b0txGBOG>I{L#6pguxJ0+2x{s03)}PYF3Oh$PgB zO)wwR>No{`B;nGIPaHu!q5JZxn!e-Nb8hEDQa%k$EmLUC_az=)8FLr6qlXqL9%Lbd z{#_t|^ruBM^amm%!2|Ih@DH8`A_2;SEK~_1TC@jgbo5S-U)@gw*q{ei0uTWp25ckK zvWSO=V}u9(t;mSSmn~h*c>4@Rf~qpX&G#b#ig&C0__3N4ij?{ne5db3nZyKgFMQH81l(zxVEUR&s)iNCVUhr?6{1pOg|a&!*rWK0a(lJSu`)VHr* z&|)M$$i$aQKgAPZk(&S2VK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5tmVuG2jq*$c1hGhM!!m`vZ94X4_xEd zU7wE{G8gj=4>r4~e_o|FG>n`LKyQkx5#xAQgNqG~2q^Y$?~TH%5q#p2AvWSeycpkS z632w-(rY_m+VfB&ACYxChh;m^Zrk}HjUb&TTC2|l)PfTB?pG-Sas0q zHRI%LqY&Z#|2P=Dt1 z(mOij7Taz_S_t{RsfBlT*SsaVuwkBJMf6W*SPj-B)mCMDxE-V9HTP=~=7{NmH&MYR zt9{}?;Aj3D`=kwz!23XYzL<7{)_Yg*g?lp<{n61CE_#b)#)lVt&bS{P8JsRiKa2=z zm>EE^R&?K|V9O0aZ?Bs(9F_OtrP@aom7auzzg2nv?tTBa-~K07oV>Bd0aO(E<)cGo zZZ}s^uw1Fj*5FX@5{XD*c^oRqw!(N-Tai`d@-6(tS4W@X%Pt)wVz6OWStIM#8Fo;W j(P6C0^Ar_TXAho)gqQz~TKfOFN~H8PU=dgNYwG_1e$XBZ diff --git a/ht/vote.php b/ht/vote.php deleted file mode 100644 index c052e14..0000000 --- a/ht/vote.php +++ /dev/null @@ -1,650 +0,0 @@ -table('vote') . " v - INNER JOIN " . $db->table('recs') . " r ON v.id = r.topic_id - WHERE r.user_id = " . $user['id'] . " - ORDER BY r.vote_time DESC"; - - $result = $db->query($sql); - $myVotes = []; - if ($result) { - while ($row = $result->fetch_assoc()) { - $myVotes[] = $row; - } - } - - // 计算分页信息 - $total = count($myVotes); - $pagination = getPagination($total, $page, $pageSize); - - // 按分页截取数据 - $myVotesList = array_slice($myVotes, $pagination['offset'], $pagination['pageSize']); - - // 页面标题 - $pageTitle = "我的投票"; - - ?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -

- -
- - -
-

我的投票记录

- - -
- - $now) { - $voteStatus = '未开始'; - $statusClass = 'vote-status-pending'; - } elseif ($vote['endtime'] < $now) { - $voteStatus = '已结束'; - $statusClass = 'vote-status-ended'; - } else { - $voteStatus = '进行中'; - $statusClass = 'vote-status-active'; - } - } - ?> -
-
-

- - -

-

- - 100): ?>... -

-

类型:

-

时间:

- -
-
- -
- - - - -
-
-

您还没有参与过任何投票

-

- 去投票 -

-
-
- -
- - - - - - getOne('vote', "id = $voteId"); -if (!$vote) { - header('Location: index.php'); - exit; -} - -// 更新浏览次数 -$db->update('vote', ['iview' => $vote['iview'] + 1], "id = $voteId"); - -// 获取投票选项 -$options = $db->getAll('xuan', "topic_id = $voteId", '*', 'sort ASC, id ASC'); - -// 检查用户是否已投票 -$hasVoted = false; -$userVotes = []; - -if ($user) { - $userVoteRecords = $db->getAll('recs', "topic_id = $voteId AND user_id = {$user['id']}"); - - if (!empty($userVoteRecords)) { - $hasVoted = true; - foreach ($userVoteRecords as $record) { - $userVotes[] = $record['option_id']; - } - } -} - -// 获取投票结果 -$voteResults = []; -$totalVotes = 0; - -$sql = "SELECT option_id, COUNT(*) as vote_count FROM " . $db->table('recs') . " WHERE topic_id = $voteId GROUP BY option_id"; -$result = $db->query($sql); - -if ($result) { - while ($row = $result->fetch_assoc()) { - $voteResults[$row['option_id']] = $row['vote_count']; - $totalVotes += $row['vote_count']; - } -} - -// 当前时间,用于判断投票状态 -$now = date('Y-m-d H:i:s'); -$canVote = $vote['status'] == 1 && $vote['statime'] <= $now && $vote['endtime'] >= $now && !$hasVoted && $user; - -// 页面标题 -$pageTitle = $vote['title']; -?> - - - - - - <?php echo $pageTitle; ?> - <?php echo getSiteTitle(); ?> - - - - - -
-
- - -
-
- - -
-
-
-

- - - $now) { - $voteStatus = '未开始'; - $statusClass = 'vote-status-pending'; - } elseif ($vote['endtime'] < $now) { - $voteStatus = '已结束'; - $statusClass = 'vote-status-ended'; - } else { - $voteStatus = '进行中'; - $statusClass = 'vote-status-active'; - } - } - ?> - -

- -
- 类型: - 时间: - 浏览: -
- -
- -
- - -

投票选项

- - - -
- - - - -
- -
- - - - - - - -
- -
- -
- -
-
- - -
- - 0 ? round(($voteCount / $totalVotes) * 100, 1) : 0; - $isUserVoted = in_array($option['id'], $userVotes); - ?> -
-
-

- - (已选) -

- - - <?php echo htmlspecialchars($option['name']); ?> - - - -

- - -
-
-
-
-
- 票 (%) -
-
-
-
- -
- - -
-

您需要登录才能参与投票

-

- 立即登录 - 注册账号 -

-
- -
-

该投票已被禁用

-
- $now): ?> -
-

该投票尚未开始,请在开始时间后再来参与

-
- -
-

该投票已经结束

-
- -
-

您已经参与过该投票,感谢您的参与!

-
- - - - -
- - 0 ? round(($voteCount / $totalVotes) * 100, 1) : 0; - ?> -
-
-

- - - <?php echo htmlspecialchars($option['name']); ?> - - - -

- - -
-
-
-
-
- 票 (%) -
-
-
-
- -
- -
-

您需要登录才能参与投票

-

- 立即登录 - 注册账号 -

-
- - -
-

暂无投票选项

-
- -
-
-
- - - - - diff --git a/ht/vote_api.php b/ht/vote_api.php deleted file mode 100644 index 8b37889..0000000 --- a/ht/vote_api.php +++ /dev/null @@ -1,490 +0,0 @@ -= 0) { - $whereConditions[] = "status = $status"; - } - if ($type >= 0) { - $whereConditions[] = "itype = $type"; - } - - $whereStr = !empty($whereConditions) ? implode(' AND ', $whereConditions) : ''; - - // 获取总记录数 - $total = $db->count('vote', $whereStr); - - // 计算分页信息 - $pagination = getPagination($total, $page, $pageSize); - - // 获取投票列表 - $orderBy = "addtime DESC"; - $limit = "{$pagination['offset']}, {$pagination['pageSize']}"; - $voteList = $db->getAll('vote', $whereStr, '*', $orderBy, $limit); - - // 当前时间,用于判断投票状态 - $now = date('Y-m-d H:i:s'); - - // 处理投票状态 - foreach ($voteList as &$vote) { - $vote['status_text'] = ''; - $vote['status_class'] = ''; - - if ($vote['status'] == 0) { - $vote['status_text'] = '已禁用'; - $vote['status_class'] = 'vote-status-disabled'; - } else { - if ($vote['statime'] > $now) { - $vote['status_text'] = '未开始'; - $vote['status_class'] = 'vote-status-pending'; - } elseif ($vote['endtime'] < $now) { - $vote['status_text'] = '已结束'; - $vote['status_class'] = 'vote-status-ended'; - } else { - $vote['status_text'] = '进行中'; - $vote['status_class'] = 'vote-status-active'; - } - } - } - - apiResponse(0, '获取成功', [ - 'list' => $voteList, - 'pagination' => $pagination - ]); -} - -/** - * 处理获取投票详情 - * @param array $params 请求参数 - * @param DB $db 数据库操作对象 - */ -function handleGetVoteDetail($params, $db) { - // 获取投票ID - $voteId = isset($params['id']) ? intval($params['id']) : 0; - - if (!$voteId) { - apiResponse(1, '参数错误'); - } - - // 获取投票信息 - $vote = $db->getOne('vote', "id = $voteId"); - if (!$vote) { - apiResponse(1, '投票不存在'); - } - - // 更新浏览次数 - $db->update('vote', ['iview' => $vote['iview'] + 1], "id = $voteId"); - - // 获取投票选项 - $options = $db->getAll('xuan', "topic_id = $voteId", '*', 'sort ASC, id ASC'); - - // 当前时间,用于判断投票状态 - $now = date('Y-m-d H:i:s'); - - // 处理投票状态 - $vote['status_text'] = ''; - $vote['status_class'] = ''; - - if ($vote['status'] == 0) { - $vote['status_text'] = '已禁用'; - $vote['status_class'] = 'vote-status-disabled'; - } else { - if ($vote['statime'] > $now) { - $vote['status_text'] = '未开始'; - $vote['status_class'] = 'vote-status-pending'; - } elseif ($vote['endtime'] < $now) { - $vote['status_text'] = '已结束'; - $vote['status_class'] = 'vote-status-ended'; - } else { - $vote['status_text'] = '进行中'; - $vote['status_class'] = 'vote-status-active'; - } - } - - // 检查用户是否已投票 - $hasVoted = false; - $userVotes = []; - $user = checkLogin(); - - if ($user) { - $userVoteRecords = $db->getAll('recs', "topic_id = $voteId AND user_id = {$user['id']}"); - - if (!empty($userVoteRecords)) { - $hasVoted = true; - foreach ($userVoteRecords as $record) { - $userVotes[] = $record['option_id']; - } - } - } - - // 计算是否可以投票 - $canVote = $vote['status'] == 1 && $vote['statime'] <= $now && $vote['endtime'] >= $now && !$hasVoted && $user; - - apiResponse(0, '获取成功', [ - 'vote' => $vote, - 'options' => $options, - 'hasVoted' => $hasVoted, - 'userVotes' => $userVotes, - 'canVote' => $canVote - ]); -} - -/** - * 处理提交投票 - * @param array $params 请求参数 - * @param DB $db 数据库操作对象 - */ -function handleSubmitVote($params, $db) { - // 验证权限 - $user = checkLogin(); - if (!$user) { - apiResponse(1, '请先登录'); - } - - // 获取参数 - $topicId = isset($params['topic_id']) ? intval($params['topic_id']) : 0; - $options = isset($params['options']) ? $params['options'] : []; - - // 参数验证 - if (empty($topicId) || empty($options)) { - apiResponse(1, '参数错误'); - } - - // 确保options是数组 - if (!is_array($options)) { - $options = explode(',', $options); - } - - if (empty($options)) { - apiResponse(1, '请至少选择一个选项'); - } - - // 获取投票信息 - $vote = $db->getOne('vote', "id = $topicId"); - if (!$vote) { - apiResponse(1, '投票不存在'); - } - - // 验证投票状态 - $now = date('Y-m-d H:i:s'); - if ($vote['status'] != 1) { - apiResponse(1, '该投票已被禁用'); - } - - if ($vote['statime'] > $now) { - apiResponse(1, '该投票尚未开始'); - } - - if ($vote['endtime'] < $now) { - apiResponse(1, '该投票已经结束'); - } - - // 检查用户是否已投票 - $hasVoted = $db->count('recs', "topic_id = $topicId AND user_id = {$user['id']}"); - if ($hasVoted > 0) { - apiResponse(1, '您已经参与过该投票'); - } - - // 验证选项数量 - if ($vote['itype'] == 1 && count($options) > $vote['maxtime']) { - apiResponse(1, "最多只能选择 {$vote['maxtime']} 项"); - } - - // 验证选项是否存在 - foreach ($options as $optionId) { - $option = $db->getOne('xuan', "id = $optionId AND topic_id = $topicId"); - if (!$option) { - apiResponse(1, '选项不存在'); - } - } - - // 开始事务 - $db->startTransaction(); - - try { - // 添加投票记录 - $ip = $_SERVER['REMOTE_ADDR']; - $time = date('Y-m-d H:i:s'); - - foreach ($options as $optionId) { - $result = $db->insert('recs', [ - 'topic_id' => $topicId, - 'user_id' => $user['id'], - 'option_id' => $optionId, - 'vote_time' => $time, - 'ip' => $ip - ]); - - if (!$result) { - throw new Exception('提交投票失败'); - } - } - - // 记录日志 - writeLog($user['id'], 'vote', "参与投票:{$vote['title']}"); - - // 提交事务 - $db->commit(); - - apiResponse(0, '投票成功'); - } catch (Exception $e) { - // 回滚事务 - $db->rollback(); - apiResponse(1, $e->getMessage()); - } -} - -/** - * 处理获取投票结果 - * @param array $params 请求参数 - * @param DB $db 数据库操作对象 - */ -function handleGetVoteResult($params, $db) { - // 获取投票ID - $voteId = isset($params['id']) ? intval($params['id']) : 0; - - if (!$voteId) { - apiResponse(1, '参数错误'); - } - - // 获取投票信息 - $vote = $db->getOne('vote', "id = $voteId"); - if (!$vote) { - apiResponse(1, '投票不存在'); - } - - // 获取选项列表 - $options = $db->getAll('xuan', "topic_id = $voteId", '*', 'sort ASC, id ASC'); - if (empty($options)) { - apiResponse(1, '暂无投票选项'); - } - - // 获取投票结果 - $sql = "SELECT option_id, COUNT(*) as vote_count FROM " . $db->table('recs') . " WHERE topic_id = $voteId GROUP BY option_id"; - $result = $db->query($sql); - - $voteResults = []; - $totalVotes = 0; - - if ($result) { - while ($row = $result->fetch_assoc()) { - $voteResults[$row['option_id']] = $row['vote_count']; - $totalVotes += $row['vote_count']; - } - } - - // 格式化结果 - $formattedResults = []; - foreach ($options as $option) { - $voteCount = isset($voteResults[$option['id']]) ? $voteResults[$option['id']] : 0; - $percentage = $totalVotes > 0 ? round(($voteCount / $totalVotes) * 100, 1) : 0; - - $formattedResults[] = [ - 'id' => $option['id'], - 'name' => $option['name'], - 'idesc' => $option['idesc'], - 'imgs' => $option['imgs'], - 'count' => $voteCount, - 'percentage' => $percentage - ]; - } - - // 用户是否已投票 - $hasVoted = false; - $userVotes = []; - $user = checkLogin(); - - if ($user) { - $userVoteRecords = $db->getAll('recs', "topic_id = $voteId AND user_id = {$user['id']}"); - - if (!empty($userVoteRecords)) { - $hasVoted = true; - foreach ($userVoteRecords as $record) { - $userVotes[] = $record['option_id']; - } - } - } - - apiResponse(0, '获取成功', [ - 'vote' => $vote, - 'options' => $formattedResults, - 'totalVotes' => $totalVotes, - 'hasVoted' => $hasVoted, - 'userVotes' => $userVotes - ]); -} - -/** - * 处理获取用户的投票记录 - * @param array $params 请求参数 - * @param DB $db 数据库操作对象 - */ -function handleGetUserVotes($params, $db) { - // 验证权限 - $user = checkLogin(); - if (!$user) { - apiResponse(1, '请先登录'); - } - - // 获取分页参数 - $page = isset($params['page']) ? intval($params['page']) : 1; - $pageSize = isset($params['pageSize']) ? intval($params['pageSize']) : 10; - - // 查询该用户参与的投票 - $sql = "SELECT DISTINCT v.* FROM " . $db->table('vote') . " v - INNER JOIN " . $db->table('recs') . " r ON v.id = r.topic_id - WHERE r.user_id = " . $user['id'] . " - ORDER BY r.vote_time DESC"; - - $result = $db->query($sql); - $myVotes = []; - if ($result) { - while ($row = $result->fetch_assoc()) { - $myVotes[] = $row; - } - } - - // 计算分页信息 - $total = count($myVotes); - $pagination = getPagination($total, $page, $pageSize); - - // 按分页截取数据 - $myVotesList = array_slice($myVotes, $pagination['offset'], $pagination['pageSize']); - - // 当前时间,用于判断投票状态 - $now = date('Y-m-d H:i:s'); - - // 处理投票状态 - foreach ($myVotesList as &$vote) { - $vote['status_text'] = ''; - $vote['status_class'] = ''; - - if ($vote['status'] == 0) { - $vote['status_text'] = '已禁用'; - $vote['status_class'] = 'vote-status-disabled'; - } else { - if ($vote['statime'] > $now) { - $vote['status_text'] = '未开始'; - $vote['status_class'] = 'vote-status-pending'; - } elseif ($vote['endtime'] < $now) { - $vote['status_text'] = '已结束'; - $vote['status_class'] = 'vote-status-ended'; - } else { - $vote['status_text'] = '进行中'; - $vote['status_class'] = 'vote-status-active'; - } - } - } - - apiResponse(0, '获取成功', [ - 'list' => $myVotesList, - 'pagination' => $pagination - ]); -} - -/** - * 统一API响应格式 - * @param int $code 状态码,0表示成功,非0表示失败 - * @param string $msg 提示信息 - * @param array $data 返回数据 - */ -function apiResponse($code = 0, $msg = '', $data = []) { - echo json_encode([ - 'code' => $code, - 'msg' => $msg, - 'data' => $data - ], JSON_UNESCAPED_UNICODE); - exit; -} \ No newline at end of file diff --git a/server_monitor.html b/server_monitor.html deleted file mode 100644 index 0d3a297..0000000 --- a/server_monitor.html +++ /dev/null @@ -1,418 +0,0 @@ - - - - - - 服务器监控面板 - - - -
-
-

🖥️ 服务器监控面板

-

实时监控服务器状态与性能

-
正在加载...
-
- -
- -
- -
-
-
- 📊 -
-
服务器负载
-
-
-
- - -
-
-
- 🌐 -
-
网络延迟
-
-
-
- - -
-
-
- ⚡ -
-
服务器响应时间
-
-
-
-
- -
最后更新: --
-
- - - - - - \ No newline at end of file diff --git a/server_monitor_api.php b/server_monitor_api.php deleted file mode 100644 index 400e775..0000000 --- a/server_monitor_api.php +++ /dev/null @@ -1,80 +0,0 @@ - round($load[0], 2), - '5min' => round($load[1], 2), - '15min' => round($load[2], 2) - ]; -} - -function getNetworkLatency() { - $hosts = [ - '8.8.8.8' => 'Google DNS', - '1.1.1.1' => 'Cloudflare DNS', - '114.114.114.114' => '114 DNS' - ]; - - $results = []; - foreach ($hosts as $ip => $name) { - $start = microtime(true); - $socket = @fsockopen($ip, 53, $errno, $errstr, 2); - $end = microtime(true); - - if ($socket) { - fclose($socket); - $latency = round(($end - $start) * 1000, 2); - $results[] = [ - 'host' => $name, - 'ip' => $ip, - 'latency' => $latency, - 'status' => 'online' - ]; - } else { - $results[] = [ - 'host' => $name, - 'ip' => $ip, - 'latency' => null, - 'status' => 'offline' - ]; - } - } - - return $results; -} - -function getTimestamp() { - return [ - 'unix' => time(), - 'datetime' => date('Y-m-d H:i:s'), - 'timezone' => date_default_timezone_get() - ]; -} - -// 记录请求开始时间 -$start_time = microtime(true); - -$response = [ - 'status' => 'success', - 'timestamp' => getTimestamp(), - 'server' => [ - 'load' => getServerLoad() - ], - 'network' => [ - 'latency' => getNetworkLatency(), - 'server_response_time' => round((microtime(true) - $start_time) * 1000, 2) // 服务器响应时间(毫秒) - ] -]; - -echo json_encode($response, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT); -?> \ No newline at end of file