Added some more services to the statistics, support of new structure for update service.

pull/217/head
Michael Vogel 2014-10-13 20:06:28 +02:00
parent 30ee2ab542
commit 250ad4528c
1 changed files with 28 additions and 11 deletions

View File

@ -37,17 +37,34 @@ function statistics_json_init() {
"local_posts" => get_config('statistics_json','local_posts') "local_posts" => get_config('statistics_json','local_posts')
); );
$statistics["facebook"] = statistics_json_plugin_enabled("fbpost"); $statistics["services"] = array();
$statistics["twitter"] = statistics_json_plugin_enabled("twitter"); $statistics["services"]["appnet"] = statistics_json_plugin_enabled("appnet");
$statistics["tumblr"] = statistics_json_plugin_enabled("tumblr"); $statistics["services"]["blogger"] = statistics_json_plugin_enabled("blogger");
$statistics["wordpress"] = statistics_json_plugin_enabled("wppost"); $statistics["services"]["buffer"] = statistics_json_plugin_enabled("buffer");
$statistics["appnet"] = statistics_json_plugin_enabled("appnet"); $statistics["services"]["dreamwidth"] = statistics_json_plugin_enabled("dwpost");
$statistics["blogger"] = statistics_json_plugin_enabled("blogger"); $statistics["services"]["facebook"] = statistics_json_plugin_enabled("fbpost");
$statistics["buffer"] = statistics_json_plugin_enabled("buffer"); $statistics["services"]["gnusocial"] = statistics_json_plugin_enabled("statusnet");
$statistics["googleplus"] = statistics_json_plugin_enabled("gpluspost"); $statistics["services"]["googleplus"] = statistics_json_plugin_enabled("gpluspost");
$statistics["libertree"] = statistics_json_plugin_enabled("libertree"); $statistics["services"]["libertree"] = statistics_json_plugin_enabled("libertree");
$statistics["pumpio"] = statistics_json_plugin_enabled("pumpio"); $statistics["services"]["livejournal"] = statistics_json_plugin_enabled("ljpost");
$statistics["gnusocial"] = statistics_json_plugin_enabled("statusnet"); $statistics["services"]["pumpio"] = statistics_json_plugin_enabled("pumpio");
$statistics["services"]["twitter"] = statistics_json_plugin_enabled("twitter");
$statistics["services"]["tumblr"] = statistics_json_plugin_enabled("tumblr");
$statistics["services"]["wordpress"] = statistics_json_plugin_enabled("wppost");
$statistics["appnet"] = $statistics["services"]["appnet"];
$statistics["blogger"] = $statistics["services"]["blogger"];
$statistics["buffer"] = $statistics["services"]["buffer"];
$statistics["dreamwidth"] = $statistics["services"]["dreamwidth"];
$statistics["facebook"] = $statistics["services"]["facebook"];
$statistics["gnusocial"] = $statistics["services"]["gnusocial"];
$statistics["googleplus"] = $statistics["services"]["googleplus"];
$statistics["libertree"] = $statistics["services"]["libertree"];
$statistics["livejournal"] = $statistics["services"]["livejournal"];
$statistics["pumpio"] = $statistics["services"]["pumpio"];
$statistics["twitter"] = $statistics["services"]["twitter"];
$statistics["tumblr"] = $statistics["services"]["tumblr"];
$statistics["wordpress"] = $statistics["services"]["wordpress"];
header("Content-Type: application/json"); header("Content-Type: application/json");
echo json_encode($statistics); echo json_encode($statistics);