For developers

Small modules you can read in an afternoon

Editloft is written so that a developer can see exactly what it does. Each feature is a module, every behaviour that a team might want to change is a filter, and the parts that matter are tested.

By Christopher Ross. Last updated .

Script

Read history without SQL

wp editloft audit <post_id> prints a post's audit trail in the same wording the editor shows. The same data is available in the REST API as a read-only field, so a dashboard or a migration script can use it.

  • WP-CLI publishes are never gated, and they are recorded
  • REST access follows the post's own edit permission

Extend

Filters where a team would want them

The transition graph, the calendar capability and the calendar query are all filterable. Change who can publish, who can see the calendar, or which posts the calendar loads, without forking the plugin.

  • A status that is not in the graph is not gated, so extending it is safe
  • GPLv2 or later: fork it if a filter is not enough

Trust

Tested and readable

A PHPUnit suite of 22 tests covers the rules per role, the audit writes and the calendar's unscheduled logic, and it runs in CI. The repository is public, issues and pull requests are welcome, and the license and upstream credits are kept intact.

Reference

Extension points

Hooks, commands and endpoints
NameTypeWhat it does
editloft_status_transition_graphFilterReshape the allowed status moves per role, or return an empty array to disable enforcement.
editloft_view_calendar_capFilterChange the capability required to see the calendar.
editloft_rest_calendar_query_argsFilterAdjust the query the calendar's REST endpoint runs.
editloft_audit_trailREST fieldRead-only audit entries on each supported post type, for people who can edit the post.
wp editloft audit <post_id>WP-CLIPrint a post's audit trail as plain sentences.
/wp-json/editloft/v1/RESTCalendar events and the date-save endpoint the calendar uses.

Questions

For developers FAQ

Is there a test suite?

Yes. A PHPUnit suite of 22 tests covers the transition rules per role, the audit log writes and the calendar's unscheduled test. It runs in CI.

How is the plugin organised?

Each feature is a module under modules/ that registers itself with a small loader. A module that is switched off loads nothing.

What are the version numbers?

Versions use the scheme 0.6DDD.HHMM, where DDD is the day of the year and HHMM is the build time. The plugin is pre-1.0.

Free, open source, GPLv2

Try Editloft on a staging copy of your site

It is free, it takes a minute to install, and you can switch each module off again from one settings screen.