WP Manifestindependent plugin directory
manifest / editor / dmg-read-more

DMG Read More

Need to link to other posts in your content? This block lets you easily search and select any post to create clean "Read More" links. Perfect for creating post series, related content, or any cross-references between your articles.

by Michel Moraes · github.com/michelmany/dmg-read-more

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/michelmany/dmg-read-more/archive/refs/heads/master.zip

Readme

dmg-read-more WordPress Plugin

Overview

The dmg-read-more plugin adds a custom Gutenberg block to your WordPress site, allowing users to easily create "Read More" links to posts. It also includes a WP-CLI command for searching posts that contain the block.

Features

  • Gutenberg Block:

    • Register a custom block using native WordPress block editor APIs.
    • Search for posts by title or Post ID.
    • Paginate results and show recent posts by default.
    • Real-time preview of selected post with a "Read More" link.
  • WP-CLI Command:

    • Custom command to search for posts containing the "Read More" block.
    • Filter posts by date, with a default of the last 30 days.
    • Outputs matching Post IDs to the console.

Installation

  1. Download the plugin files and place them in the wp-content/plugins/dmg-read-more directory.
  2. Activate the plugin through the 'Plugins' menu in WordPress.

Usage

Gutenberg Block

  • Add the "Read More" block to your post or page.
  • Use the InspectorControls to search for posts and select one.
  • The selected post will be displayed as a "Read More" link.

WP-CLI Command

  • Use the command:
    wp dmg-read-more search [--date-before=YYYY-MM-DD] [--date-after=YYYY-MM-DD]
  • If no dates are provided, it will search for posts from the last 30 days.

Development

  • The plugin uses modern JavaScript and WordPress APIs.
  • Ensure you have Node.js and npm installed for building the block assets.

Read the full README on GitHub →