diff options
Diffstat (limited to 'central/trunk/xmlrpc.php')
-rw-r--r-- | central/trunk/xmlrpc.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/central/trunk/xmlrpc.php b/central/trunk/xmlrpc.php index c638401..7dd5be7 100644 --- a/central/trunk/xmlrpc.php +++ b/central/trunk/xmlrpc.php | |||
@@ -80,7 +80,7 @@ function sendFromUpdate($username, $verification, $verificationID, $subscription | |||
80 | { | 80 | { |
81 | if (instaDisc_checkVerification($username, $verification, $verificationID, 'users', 'username', 'password')) | 81 | if (instaDisc_checkVerification($username, $verification, $verificationID, 'users', 'username', 'password')) |
82 | { | 82 | { |
83 | $getusubs = "SELECT * FROM subscriptions WHERE username = \"" . mysql_real_escape_string($username) . "\" AND url = \"" . mysql_real_escape_string($subscription) . "\" AND owner = \"true\""; | 83 | $getusubs = "SELECT * FROM subscriptions WHERE username = \"" . mysql_real_escape_string($username) . "\" AND url = \"" . mysql_real_escape_string($subscription) . "\" AND owner = \"true\" AND category <> \"instadisc\""; |
84 | $getusubs2 = mysql_query($getusubs); | 84 | $getusubs2 = mysql_query($getusubs); |
85 | $getusubs3 = mysql_fetch_array($getusubs2); | 85 | $getusubs3 = mysql_fetch_array($getusubs2); |
86 | if ($getusubs3['username'] == $username) | 86 | if ($getusubs3['username'] == $username) |
@@ -163,7 +163,7 @@ function sendFromCentral($cserver, $verification, $verificationID, $subscription | |||
163 | instaDisc_sendDatabase($cserver); | 163 | instaDisc_sendDatabase($cserver); |
164 | } | 164 | } |
165 | 165 | ||
166 | $getsed = "SELECT * FROM subscriptions WHERE url = \"" . mysql_real_escape_string($subscription) . "\" AND owner = \"false\""; | 166 | $getsed = "SELECT * FROM subscriptions WHERE url = \"" . mysql_real_escape_string($subscription) . "\" AND owner = \"false\" AND category <> \"instadisc\""; |
167 | $getsed2 = mysql_query($getsed); | 167 | $getsed2 = mysql_query($getsed); |
168 | $i=0; | 168 | $i=0; |
169 | while ($getsed3[$i] = mysql_fetch_array($getsed2)) | 169 | while ($getsed3[$i] = mysql_fetch_array($getsed2)) |
@@ -227,7 +227,7 @@ function deleteSubscription($username, $verification, $verificationID, $subscrip | |||
227 | return new xmlrpcresp(new xmlrpcval(1, "int")); | 227 | return new xmlrpcresp(new xmlrpcval(1, "int")); |
228 | } | 228 | } |
229 | 229 | ||
230 | function addSubscription($username, $verification, $verificationID, $subscription) | 230 | function addSubscription($username, $verification, $verificationID, $subscription, $category) |
231 | { | 231 | { |
232 | if (instaDisc_checkVerification($username, $verification, $verificationID, 'users', 'username', 'password')) | 232 | if (instaDisc_checkVerification($username, $verification, $verificationID, 'users', 'username', 'password')) |
233 | { | 233 | { |
@@ -236,7 +236,7 @@ function addSubscription($username, $verification, $verificationID, $subscriptio | |||
236 | $getsub3 = mysql_fetch_array($getsub2); | 236 | $getsub3 = mysql_fetch_array($getsub2); |
237 | if ($getsub3['url'] == $subscription) | 237 | if ($getsub3['url'] == $subscription) |
238 | { | 238 | { |
239 | $inssub = "INSERT INTO subscriptions (url, username, owner) VALUES (\"" . mysql_real_escape_string($subscription) . "\", \"" . mysql_real_escape_string($username) . "\", \"false\")"; | 239 | $inssub = "INSERT INTO subscriptions (url, username, owner, category) VALUES (\"" . mysql_real_escape_string($subscription) . "\", \"" . mysql_real_escape_string($username) . "\", \"false\", \"" . mysql_real_escape_string($category) . "\")"; |
240 | $inssub2 = mysql_query($inssub); | 240 | $inssub2 = mysql_query($inssub); |
241 | 241 | ||
242 | return new xmlrpcresp(new xmlrpcval(0, "int")); | 242 | return new xmlrpcresp(new xmlrpcval(0, "int")); |