diff options
-rw-r--r-- | central/trunk/includes/instadisc.php | 15 | ||||
-rw-r--r-- | central/trunk/subscription.php | 9 | ||||
-rw-r--r-- | central/trunk/xmlrpc.php | 24 |
3 files changed, 8 insertions, 40 deletions
diff --git a/central/trunk/includes/instadisc.php b/central/trunk/includes/instadisc.php index 438fcfb..003ad1b 100644 --- a/central/trunk/includes/instadisc.php +++ b/central/trunk/includes/instadisc.php | |||
@@ -237,19 +237,4 @@ function instaDisc_changePassword($username, $password) | |||
237 | $setpass2 = mysql_query($setpass); | 237 | $setpass2 = mysql_query($setpass); |
238 | } | 238 | } |
239 | 239 | ||
240 | function instaDisc_resolveSubscription($seriesURL, $id) | ||
241 | { | ||
242 | $client = new xmlrpc_client($seriesURL); | ||
243 | $msg = new xmlrpcmsg('InstaDisc.subscriptionInfo', array( new xmlrpcval($id, 'string'))); | ||
244 | $resp = $client->send($msg); | ||
245 | $val = $resp->value()->scalarVal(); | ||
246 | |||
247 | if ($val == 'false') | ||
248 | { | ||
249 | return 'false'; | ||
250 | } else { | ||
251 | return unserialize($val); | ||
252 | } | ||
253 | } | ||
254 | |||
255 | ?> | 240 | ?> |
diff --git a/central/trunk/subscription.php b/central/trunk/subscription.php deleted file mode 100644 index 9b6a61c..0000000 --- a/central/trunk/subscription.php +++ /dev/null | |||
@@ -1,9 +0,0 @@ | |||
1 | <?php | ||
2 | |||
3 | /* InstaDisc Server - A Four Island Project */ | ||
4 | |||
5 | include('includes/instadisc.php'); | ||
6 | |||
7 | ?>Subscription: http://fourisland.com/<?php echo($_SERVER['SERVER_NAME'] . "\n"); ?> | ||
8 | Title: <?php echo(instaDisc_getConfig('siteName') . "\n"); ?> | ||
9 | Category: instadisc | ||
diff --git a/central/trunk/xmlrpc.php b/central/trunk/xmlrpc.php index f8f5beb..0254e66 100644 --- a/central/trunk/xmlrpc.php +++ b/central/trunk/xmlrpc.php | |||
@@ -75,26 +75,18 @@ function requestRetained($username, $verification, $verificationID) | |||
75 | return new xmlrpcresp(new xmlrpcval(1, "int")); | 75 | return new xmlrpcresp(new xmlrpcval(1, "int")); |
76 | } | 76 | } |
77 | 77 | ||
78 | function sendFromUpdate($subscriptionSeriesURL, $subscriptionID, $title, $author, $url, $semantics, $encryptionID) | 78 | function sendFromUpdate($subscriptionURL, $title, $author, $url, $semantics, $encryptionID) |
79 | { | 79 | { |
80 | $subscriptionURL = instaDisc_resolveSubscription($subscriptionSeriesURL, $subscriptionID); | 80 | $getsed = "SELECT * FROM subscriptions WHERE url = \"" . mysql_real_escape_string($subscriptionURL) . "\""; |
81 | if ($subscriptionURL != 'false') | 81 | $getsed2 = mysql_query($getsed); |
82 | $i=0; | ||
83 | while ($getsed3[$i] = mysql_fetch_array($getsed2)) | ||
82 | { | 84 | { |
83 | $subscriptionURL = $subscriptionURL['url']; | 85 | instaDisc_addItem($getsed3[$i]['username'], $subscriptionURL, $title, $author, $url, $semantics, $encryptionID); |
84 | 86 | $i++; | |
85 | $getsed = "SELECT * FROM subscriptions WHERE url = \"" . mysql_real_escape_string($subscriptionURL) . "\""; | ||
86 | $getsed2 = mysql_query($getsed); | ||
87 | $i=0; | ||
88 | while ($getsed3[$i] = mysql_fetch_array($getsed2)) | ||
89 | { | ||
90 | instaDisc_addItem($getsed3[$i]['username'], $subscriptionURL, $title, $author, $url, $semantics, $encryptionID); | ||
91 | $i++; | ||
92 | } | ||
93 | |||
94 | return new xmlrpcresp(new xmlrpcval(0, "int")); | ||
95 | } | 87 | } |
96 | 88 | ||
97 | return new xmlrpcresp(new xmlrpcval(1, "int")); | 89 | return new xmlrpcresp(new xmlrpcval(0, "int")); |
98 | } | 90 | } |
99 | 91 | ||
100 | function deleteSubscription($username, $verification, $verificationID, $subscription) | 92 | function deleteSubscription($username, $verification, $verificationID, $subscription) |