wponrails / wp-relinquish

Helps WP to relinquish content serving to another system by sending notifications as webhook calls.
MIT License
12 stars 0 forks source link

wp-relinquish

Scrutinizer Code Quality Build Status

This WordPress plugin is part of the WP on Rails project, which limits a WP's responsibilities to managing content while entrusting a Rails application with serving public request and providing a basis for customizations.

The wp-relinquish plugin —as the name implies— helps WordPress to "relinquish" content serving to an external system. In case of the WP on Rails architecture that is a Rails application with wp-connector installed.

The following plugins are needed or recommended when using wp-relinquish to setup a WP on Rails architecture:

This plugin provides the following functionality:

This plugin does not transfer content into the external system, it only helps sending notifications as webhook calls.

Please refer to the README of the wp-connector gem for a detailed explaination of why moving "content serving" out of WP is a good idea and how this is achieved.

Getting started

The end-point url, where all webhook calls will be made to, can be set in two different ways.

By (1) defining a constant:

define( 'RELINQUISH_TO', 'http://example.com/wp-webhook-endpoint' );

Or by (2) adding a filter:

add_filter( 'wp_relinquish/relinqish_to', 'relinqish_to' );

function relinqish_to( $url ) {
  return 'http://example.com/wp-webhook-endpoint';
}

Contributing

Contributions are most welcome! You know the drill: create issue, fork, resolve issue, submit pull request.

License

(c) Copyright 2015, Hoppinger B.V.

MIT licensed, as found in the LICENSE file.