about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--central/trunk/xmlrpc.php12
1 files changed, 11 insertions, 1 deletions
diff --git a/central/trunk/xmlrpc.php b/central/trunk/xmlrpc.php index 0e66940..ea77e3f 100644 --- a/central/trunk/xmlrpc.php +++ b/central/trunk/xmlrpc.php
@@ -237,6 +237,15 @@ function deinitalizePort($username, $verification, $verificationID)
237 return new xmlrpcresp(new xmlrpcval('1', 'int')); 237 return new xmlrpcresp(new xmlrpcval('1', 'int'));
238} 238}
239 239
240function countSubscribers($url)
241{
242 $cntsub = "SELECT * FROM subscriptions WHERE url = \"" . mysql_real_escape_string($url) . "\"";
243 $cntsub2 = mysql_query($cntsub);
244 $cntsub3 = mysql_fetch_array($cntsub2);
245
246 return new xmlrpcresp(new xmlrpcval($cntsub3[0], 'int'));
247}
248
240$s = new xmlrpc_server( array( "InstaDisc.checkRegistration" => array("function" => "checkRegistration"), 249$s = new xmlrpc_server( array( "InstaDisc.checkRegistration" => array("function" => "checkRegistration"),
241 "InstaDisc.deleteItem" => array("function" => "deleteItem"), 250 "InstaDisc.deleteItem" => array("function" => "deleteItem"),
242 "InstaDisc.resendItem" => array("function" => "resendItem"), 251 "InstaDisc.resendItem" => array("function" => "resendItem"),
@@ -248,7 +257,8 @@ $s = new xmlrpc_server( array( "InstaDisc.checkRegistration" => array("function"
248 "InstaDisc.downloadItemModeTest" => array("function" => "downloadItemModeTest"), 257 "InstaDisc.downloadItemModeTest" => array("function" => "downloadItemModeTest"),
249 "InstaDisc.setDownloadItemMode" => array("function" => "setDownloadItemMode"), 258 "InstaDisc.setDownloadItemMode" => array("function" => "setDownloadItemMode"),
250 "InstaDisc.initalizePort" => array("function" => "initalizePort"), 259 "InstaDisc.initalizePort" => array("function" => "initalizePort"),
251 "InstaDisc.deinitalizePort" => array("function" => "deinitalizePort") 260 "InstaDisc.deinitalizePort" => array("function" => "deinitalizePort"),
261 "InstaDisc.countSubscribers" => array("function" => "countSubscribers")
252 ),0); 262 ),0);
253$s->functions_parameters_type = 'phpvals'; 263$s->functions_parameters_type = 'phpvals';
254$s->service(); 264$s->service();