Version Description
Download this release
Release Info
| Developer | tcrsavage |
| Plugin | |
| Version | 2.7.3 |
| Comparing to | |
| See all releases | |
Code changes from version 2.7.2 to 2.7.3
- CONTRIBUTING.md +2 -2
- plugin.php +2 -1
- readme.txt +6 -1
- wprp.api.php +10 -9
- wprp.content.php +31 -0
CONTRIBUTING.md
CHANGED
|
@@ -4,8 +4,8 @@
|
|
| 4 |
|
| 5 |
* Develop on a feature branch and send a pull request for review.
|
| 6 |
* Assign the pull request to one of the following contacts:
|
| 7 |
-
* Primary:
|
| 8 |
-
* Secondary:
|
| 9 |
|
| 10 |
## Coding Standards ##
|
| 11 |
|
| 4 |
|
| 5 |
* Develop on a feature branch and send a pull request for review.
|
| 6 |
* Assign the pull request to one of the following contacts:
|
| 7 |
+
* Primary: Theo Savage [@tcrsavage](https://github.com/tcrsavage)
|
| 8 |
+
* Secondary: Joe Hoyle [@joe_hoyle](https://github.com/joehoyle)
|
| 9 |
|
| 10 |
## Coding Standards ##
|
| 11 |
|
plugin.php
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
/*
|
| 4 |
Plugin Name: WP Remote
|
| 5 |
Description: Manage your WordPress site with <a href="https://wpremote.com/">WP Remote</a>. <strong>Deactivate to clear your API Key.</strong>
|
| 6 |
-
Version: 2.7.
|
| 7 |
Author: Human Made Limited
|
| 8 |
Author URI: http://hmn.md/
|
| 9 |
*/
|
|
@@ -91,6 +91,7 @@ function wprp_catch_api_call() {
|
|
| 91 |
require_once( WPRP_PLUGIN_PATH . '/wprp.integration.php' );
|
| 92 |
require_once( WPRP_PLUGIN_PATH . '/wprp.plugins.php' );
|
| 93 |
require_once( WPRP_PLUGIN_PATH . '/wprp.themes.php' );
|
|
|
|
| 94 |
|
| 95 |
require_once( WPRP_PLUGIN_PATH . '/wprp.api.php' );
|
| 96 |
|
| 3 |
/*
|
| 4 |
Plugin Name: WP Remote
|
| 5 |
Description: Manage your WordPress site with <a href="https://wpremote.com/">WP Remote</a>. <strong>Deactivate to clear your API Key.</strong>
|
| 6 |
+
Version: 2.7.3
|
| 7 |
Author: Human Made Limited
|
| 8 |
Author URI: http://hmn.md/
|
| 9 |
*/
|
| 91 |
require_once( WPRP_PLUGIN_PATH . '/wprp.integration.php' );
|
| 92 |
require_once( WPRP_PLUGIN_PATH . '/wprp.plugins.php' );
|
| 93 |
require_once( WPRP_PLUGIN_PATH . '/wprp.themes.php' );
|
| 94 |
+
require_once( WPRP_PLUGIN_PATH . '/wprp.content.php' );
|
| 95 |
|
| 96 |
require_once( WPRP_PLUGIN_PATH . '/wprp.api.php' );
|
| 97 |
|
readme.txt
CHANGED
|
@@ -3,7 +3,7 @@ Contributors: humanmade, willmot, joehoyle, danielbachhuber, mattheu, pauldewout
|
|
| 3 |
Tags: wpremote, remote administration, multiple wordpress
|
| 4 |
Requires at least: 3.0
|
| 5 |
Tested up to: 3.8.1
|
| 6 |
-
Stable tag: 2.7.
|
| 7 |
|
| 8 |
WP Remote is a free web app that enables you to easily manage all of your WordPress powered sites from one place.
|
| 9 |
|
|
@@ -37,6 +37,11 @@ You can email us at support@wpremote.com for support.
|
|
| 37 |
|
| 38 |
== Changelog ==
|
| 39 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 40 |
#### 2.7.2 (22 January 2014)
|
| 41 |
|
| 42 |
* Misc improvements to the accuracy of the backup restart mechanism.
|
| 3 |
Tags: wpremote, remote administration, multiple wordpress
|
| 4 |
Requires at least: 3.0
|
| 5 |
Tested up to: 3.8.1
|
| 6 |
+
Stable tag: 2.7.3
|
| 7 |
|
| 8 |
WP Remote is a free web app that enables you to easily manage all of your WordPress powered sites from one place.
|
| 9 |
|
| 37 |
|
| 38 |
== Changelog ==
|
| 39 |
|
| 40 |
+
#### 2.7.3 (12 May 2014)
|
| 41 |
+
|
| 42 |
+
* Added the ability to return basic content information for the site - post count, user count, plugin count etc.
|
| 43 |
+
* Updated contribution guidelines
|
| 44 |
+
|
| 45 |
#### 2.7.2 (22 January 2014)
|
| 46 |
|
| 47 |
* Misc improvements to the accuracy of the backup restart mechanism.
|
wprp.api.php
CHANGED
|
@@ -92,7 +92,7 @@ include_once ( ABSPATH . 'wp-admin/includes/admin.php' );
|
|
| 92 |
$actions = array();
|
| 93 |
|
| 94 |
foreach( WPR_API_Request::get_actions() as $action ) {
|
| 95 |
-
|
| 96 |
// TODO Instead should just fire actions which we hook into.
|
| 97 |
// TODO should namespace api methods?
|
| 98 |
switch( $action ) {
|
|
@@ -275,15 +275,16 @@ foreach( WPR_API_Request::get_actions() as $action ) {
|
|
| 275 |
break;
|
| 276 |
|
| 277 |
case 'get_site_info' :
|
| 278 |
-
|
| 279 |
-
$actions[$action]
|
| 280 |
-
'site_url'
|
| 281 |
-
'home_url'
|
| 282 |
-
'admin_url'
|
| 283 |
-
'backups'
|
| 284 |
-
'web_host'
|
|
|
|
| 285 |
);
|
| 286 |
-
|
| 287 |
break;
|
| 288 |
|
| 289 |
case 'get_option':
|
| 92 |
$actions = array();
|
| 93 |
|
| 94 |
foreach( WPR_API_Request::get_actions() as $action ) {
|
| 95 |
+
|
| 96 |
// TODO Instead should just fire actions which we hook into.
|
| 97 |
// TODO should namespace api methods?
|
| 98 |
switch( $action ) {
|
| 275 |
break;
|
| 276 |
|
| 277 |
case 'get_site_info' :
|
| 278 |
+
|
| 279 |
+
$actions[$action] = array(
|
| 280 |
+
'site_url' => get_site_url(),
|
| 281 |
+
'home_url' => get_home_url(),
|
| 282 |
+
'admin_url' => get_admin_url(),
|
| 283 |
+
'backups' => function_exists( '_wprp_get_backups_info' ) ? _wprp_get_backups_info() : array(),
|
| 284 |
+
'web_host' => _wprp_integration_get_web_host(),
|
| 285 |
+
'summary' => _wprp_get_content_summary(),
|
| 286 |
);
|
| 287 |
+
|
| 288 |
break;
|
| 289 |
|
| 290 |
case 'get_option':
|
wprp.content.php
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
|
| 3 |
+
/**
|
| 4 |
+
* Return an array of content summary information
|
| 5 |
+
*
|
| 6 |
+
* @return array
|
| 7 |
+
*/
|
| 8 |
+
function _wprp_get_content_summary() {
|
| 9 |
+
|
| 10 |
+
$num_posts = wp_count_posts( 'post' );
|
| 11 |
+
$num_pages = wp_count_posts( 'page' );
|
| 12 |
+
$num_categories = count( get_categories( array( 'hide_empty' => 0 ) ) );
|
| 13 |
+
$num_comments = wp_count_comments();
|
| 14 |
+
$num_themes = count( wp_get_themes() );
|
| 15 |
+
$num_plugins = count( get_plugins() );
|
| 16 |
+
$num_users = count_users();
|
| 17 |
+
|
| 18 |
+
$content_summary = array(
|
| 19 |
+
'post_count' => ( ! empty( $num_posts->publish ) ) ? $num_posts->publish : 0,
|
| 20 |
+
'page_count' => ( ! empty( $num_pages->publish ) ) ? $num_pages->publish : 0,
|
| 21 |
+
'category_count' => $num_categories,
|
| 22 |
+
'comment_count' => ( ! empty( $num_comments->total_comments ) ) ? $num_comments->total_comments: 0,
|
| 23 |
+
'theme_count' => $num_themes,
|
| 24 |
+
'plugin_count' => $num_plugins,
|
| 25 |
+
'user_count' => ( ! empty( $num_users['total_users'] ) ) ? $num_users['total_users'] : 0
|
| 26 |
+
);
|
| 27 |
+
|
| 28 |
+
return $content_summary;
|
| 29 |
+
}
|
| 30 |
+
|
| 31 |
+
|
