renderbit/faq-jsonld 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

renderbit/faq-jsonld

Composer 安装命令:

composer require renderbit/faq-jsonld

包简介

WordPress plugin to manage FAQ items as CPT and inject FAQ JSON-LD with advanced caching and queueing.

README 文档

README

A WordPress plugin to manage FAQ items as a custom post type (CPT) and inject FAQ JSON-LD into posts/pages. Designed for performance and scalability with advanced cache management, background queueing, and admin/CLI tools.

Features

  • Custom Post Type: Manage FAQ items via the faq_item CPT.
  • Mapping Table: Fast MySQL table (fqj_mappings) links FAQ items to posts, post types, terms, URLs, or global context.
  • JSON-LD Output: Injects FAQ schema on the frontend, with per-post transient caching.
  • Cache Invalidation: Background queue (WP-Cron or WP-CLI) for efficient cache purging.
  • Admin UI: Meta boxes and settings for mapping, output, and diagnostics.
  • Health & Diagnostics: Admin page for queue/logs and manual actions.
  • WP-CLI Integration: Commands for cache and queue management.

Installation

  1. Copy the plugin folder to your WordPress wp-content/plugins/ directory.
  2. Activate via the WordPress admin Plugins page.
  3. On activation, the mapping table is created automatically.

Usage

  • Add FAQ Items: Use the FAQ Items CPT in the admin menu.
  • Associate FAQs: Use meta boxes to link FAQs to posts, post types, terms, URLs, or globally.
  • Settings: Configure cache TTL, batch size, and output type under the FAQ Items > Settings menu.
  • Health: Monitor queue/logs and run manual actions under FAQ Items > Health.
  • WP-CLI:
    • wp fqj purge-transients — Purge all FAQ JSON-LD transients.
    • wp fqj process-queue [--limit=N] — Process the invalidation queue.

Developer Notes

  • Key Files:
    • faq-jsonld.php: Main loader and CPT registration
    • includes/indexer.php: Mapping table logic
    • includes/queue.php: Invalidation queue
    • includes/frontend.php: JSON-LD output/caching
    • includes/admin.php: Admin UI/meta boxes
    • includes/settings.php: Settings page
    • includes/health.php: Health/diagnostics UI
    • includes/wpcli.php: WP-CLI commands
    • assets/js/fqj-admin.js: Admin JS (Select2, AJAX)
  • Mapping Types: All associations are stored in a single table for fast lookups.
  • Transient Keys: fqj_faq_json_{post_id}
  • Admin JS: Uses Select2 for post selectors, AJAX for search (fqj_search_posts action).
  • Background Processing: Invalidation queue is processed every 5 minutes by WP-Cron.

Contributing

Pull requests and issues are welcome. Please follow project conventions and review inline comments in each file for guidance.

License

GPLv2+

For more details, see the inline comments in each file or the .github/copilot-instructions.md for AI agent guidance.

renderbit/faq-jsonld 适用场景与选型建议

renderbit/faq-jsonld 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 0 次下载、GitHub Stars 达 1, 最近一次更新时间为 2025 年 11 月 26 日, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 renderbit/faq-jsonld 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 renderbit/faq-jsonld 我们能提供哪些服务?
定制开发 / 二次开发

基于 renderbit/faq-jsonld 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 22
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2025-11-26