Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
cies committed May 4, 2015
1 parent 4901e6e commit bb76b3b
Showing 1 changed file with 19 additions and 15 deletions.
34 changes: 19 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,37 +4,41 @@ wp-relinquish
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/hoppinger/wp-relinquish/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/hoppinger/wp-relinquish/?branch=master)
[![Build Status](https://scrutinizer-ci.com/g/hoppinger/wp-relinquish/badges/build.png?b=master)](https://scrutinizer-ci.com/g/hoppinger/wp-relinquish/build-status/master)

With this plugin [WordPress](http://wordpress.org) can *relinquish* content serving to an external system, for instance a Rails application with the [wp-connector](https://github.com/hoppinger/wp-connector) gem.
This plugin helps [WordPress](http://wordpress.org) to *relinquish* content serving to an external system, for instance a Rails application with [wp-connector](https://github.com/hoppinger/wp-connector) installed.

This plugin provides the following functionality:

* Adds configurable webhook-notifications to WP's actions, thereby allowing the external system to be informed of content changes.
* Provides a means to serve WP's admin bar, so it may be used the website that the external system serves.
* It makes it very easy setup [webhook](http://en.wikipedia.org/wiki/Webhook)-notifications for WP actions, thereby allowing the external system to be informed of content changes (addition/modification/removal).
* Provides a means to serve WP's admin bar, so it may be embedded by the external system that WP *reliquishes* content serving to. This to ensure a fully functioning the admin bar is still available to admins.

This plugin does not transfer content into the external system, we recommend to use the [WP REAST API](http://wp-api.org/) for that. Please refer to [the README of the wp-connector gem](https://github.com/hoppinger/wp-connector/blob/master/README.md) for a detailed explaination of *why* moving "content serving" out of WP is a good idea and *how* this is achieved.

Please refer to [the README of the wp-connector gem](https://github.com/hoppinger/wp-connector/blob/master/README.md) for a detailed explaination of *why* splitting "content serving" out of WP is a good idea, and *how* this is achieved.

## Getting started

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

Defining a constant:
By (1) defining a constant:

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

or add a filter:
```
add_filter( 'wp_relinquish/relinqish_to', 'relinqish_to' );
Or by (2) adding a filter:

function relinqish_to( $url ) {
return 'http://example.com/';
}
```php
add_filter( 'wp_relinquish/relinqish_to', 'relinqish_to' );

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


## Contributing

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


## License

Expand Down

0 comments on commit bb76b3b

Please sign in to comment.