wp-kit/gutenberg-object-plugin 问题修复 & 功能扩展

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

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

wp-kit/gutenberg-object-plugin

Composer 安装命令:

composer require wp-kit/gutenberg-object-plugin

包简介

Saving Gutenberg as a clean array of data to the database

README 文档

README

The purpose of this plugin is to save Gutenberg (New WordPress Editor) data as an array in the database which is accessible via the REST API.

Forked from royboy789, this plugin is intended for to be used with Rest-Kit. This plugin adds in some ACF support too with a predictable and useful JSON output. It's similar to acf-to-rest-api plugin but applies to Blocks.

Installation (With Rest-Kit)

  • Run composer require wp-kit/gutenberg-object-plugin
  • Add 'GUTENBERG_OBJECT_PLUGIN_CPTS' => 'page' to resources/config/constants.config.php
  • Add GutesObjectPlugin\Provider::class to resources/config/providers.config.php

Installation (Wordpress)

  • Download Zip and upload to Wordpress plugin directory
  • Add define('GUTENBERG_OBJECT_PLUGIN_CPTS', 'page'); to functions.php
  • Add (new GutesObjectPlugin\Provider)->register(); to functions.php

Database

Data will be saved in a new database table [prefix]_gutes_arrays

JSON

Block data gets appended editor_blocks on the normal page/post responses.

Endpoints

Includes 1 new route:

  • wp-json/gutes-db/v1/[post-id] - Supports GET & POST
  • wp-json/gutes-db/v1/[post-id]/revisions - Supports GET only

GET

GET: wp-json/gutes-db/v1/[post-id] Returns

  • is_gutes: Is the post created with Gutenberg
  • post_id: Post ID
  • data: Gutenberg Data
  • _embedded['post']: optional with _embed - response from WP REST API for post

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: GPL-3.0
  • 更新时间: 2019-05-30

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固