This plugin adds API-like functionality to your WordPress instance.
|Author:||Marko Jakic (profile at wordpress.org)|
|WordPress version required:||3.8|
|WordPress version tested:||4.1.1|
|Added to WordPress repository:||02-05-2014|
Warning! This plugin has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.
Click to start download
WordPress on Routes is a plugin for WordPress, inspired mainly by Ruby micro-frameworks. It adds ability to add custom routes to your WordPress instance. Useful for form submissions, API-like features, etc.
This plugin allows you to:
- Add custom routes to your WordPress installation
- Set method GET/POST/DELETE etc.
- Set body (as text, or template) or action (using add/do_action). If both are defined,
actiontakes precedence over
- Set header (e.g. 'Content-Type' => 'text/html; charset=UTF-8')
- Exclude header (e.g. 'Set-Cookie')
- Set parameter like '/my/route/:param1/:param2'
- Add agents or filter by agents, using regular expressions
- Agent filter for negative logic (e.g. /^((?!Firefox).)$/, which tells "every browser except Firefox")
- Include header and footer
For basic and advanced usage examples, take a look at https://github.com/markzero/wp-on-routes.
- Added predefined path
/posts.jsonto get all posts list as application/json response
- Added test environment and some tests for methods, parameters and splats