diff options
Diffstat (limited to 'series/core/trunk/includes/instadisc.php')
-rw-r--r-- | series/core/trunk/includes/instadisc.php | 72 |
1 files changed, 0 insertions, 72 deletions
diff --git a/series/core/trunk/includes/instadisc.php b/series/core/trunk/includes/instadisc.php deleted file mode 100644 index dd879c6..0000000 --- a/series/core/trunk/includes/instadisc.php +++ /dev/null | |||
@@ -1,72 +0,0 @@ | |||
1 | <?php | ||
2 | |||
3 | /* InstaDisc Series - A Four Island Project */ | ||
4 | |||
5 | include('includes/db.php'); | ||
6 | include('includes/template.php'); | ||
7 | include('includes/xmlrpc/xmlrpc.inc'); | ||
8 | include('includes/xmlrpc/xmlrpcs.inc'); | ||
9 | |||
10 | function instaDisc_subscriptionExists($id) | ||
11 | { | ||
12 | $getsub = "SELECT * FROM subscriptions WHERE identity = \"" . mysql_real_escape_string($id) . "\""; | ||
13 | $getsub2 = mysql_query($getsub); | ||
14 | $getsub3 = mysql_fetch_array($getsub2); | ||
15 | if ($getsub3['identity'] != $id) | ||
16 | { | ||
17 | return 'false'; | ||
18 | } else { | ||
19 | return 'true'; | ||
20 | } | ||
21 | } | ||
22 | |||
23 | function instaDisc_getSubscription($id) | ||
24 | { | ||
25 | $getsub = "SELECT * FROM subscriptions WHERE identity = \"" . mysql_real_escape_string($id) . "\""; | ||
26 | $getsub2 = mysql_query($getsub); | ||
27 | $getsub3 = mysql_fetch_array($getsub2); | ||
28 | |||
29 | return $getsub3; | ||
30 | } | ||
31 | |||
32 | function instaDisc_getAllSubscriptions() | ||
33 | { | ||
34 | $getsubs = "SELECT * FROM subscriptions"; | ||
35 | $getsubs2 = mysql_query($getsubs); | ||
36 | $i=0; | ||
37 | while ($getsubs3[$i] = mysql_fetch_array($getsubs2)) | ||
38 | { | ||
39 | $i++; | ||
40 | } | ||
41 | |||
42 | return $getsubs3; | ||
43 | } | ||
44 | |||
45 | function instaDisc_getConfig($name) | ||
46 | { | ||
47 | $getconfig = "SELECT * FROM config WHERE name = \"" . mysql_real_escape_string($name) . "\""; | ||
48 | $getconfig2 = mysql_query($getconfig); | ||
49 | $getconfig3 = mysql_fetch_array($getconfig2); | ||
50 | |||
51 | return $getconfig3['value']; | ||
52 | } | ||
53 | |||
54 | function instaDisc_verifyUser($username, $password) | ||
55 | { | ||
56 | return (($username == instaDisc_getConfig('adminUser')) && (md5($password) == instaDisc_getConfig('adminPass'))); | ||
57 | } | ||
58 | |||
59 | function instaDisc_changePassword($password) | ||
60 | { | ||
61 | $setconfig = "UPDATE config SET value = \"" . mysql_real_escape_string(md5($password)) . "\" WHERE name = \"adminPass\""; | ||
62 | $setconfig2 = mysql_query($setconfig); | ||
63 | $setconfig3 = mysql_fetch_array($setconfig2); | ||
64 | } | ||
65 | |||
66 | function instaDisc_addSubscription($id, $title, $url, $category, $password = '') | ||
67 | { | ||
68 | $inssub = "INSERT INTO subscriptions (identity, title, url, category, password, personal) VALUES (\"" . mysql_real_escape_string($id) . "\",\"" . mysql_real_escape_string($title) . "\",\"" . mysql_real_escape_string($url) . "\",\"" . mysql_real_escape_string($category) . "\",\"" . mysql_real_escape_string(($password == '' ? '' : md5($password))) . "\",\"false\")"; | ||
69 | $inssub2 = mysql_query($inssub); | ||
70 | } | ||
71 | |||
72 | ?> | ||