From ad9f73b06a36a832eb88358165fa1f3644581381 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Tue, 26 Aug 2008 20:56:53 +0000 Subject: Central: Fixed a few typos/errors [15]. Refs #25 --- central/trunk/includes/instadisc.php | 14 +++++++------- central/trunk/mansub.php | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'central/trunk') diff --git a/central/trunk/includes/instadisc.php b/central/trunk/includes/instadisc.php index 6b3d630..d00893b 100644 --- a/central/trunk/includes/instadisc.php +++ b/central/trunk/includes/instadisc.php @@ -301,24 +301,24 @@ function instaDisc_addSubscription($username, $url) $page_data = curl_exec($c); curl_close($c); - $headers = split("\n", $page_date); + $headers = split("\n", $page_data); foreach ($headers as $name => $value) { $header = split(": ", $value); $headerMap[$header[0]] = $header[1]; } - if (isset($header['Subscription'])) + if (isset($headerMap['Subscription'])) { - if (isset($header['Title'])) + if (isset($headerMap['Title'])) { - if (isset($header['Category'])) + if (isset($headerMap['Category'])) { - if (isset($header['Key'])) + if (isset($headerMap['Key'])) { - if ($header['Key'] == $getcode3['code']) + if ($headerMap['Key'] == $getcode3['code']) { - $inssub = "INSERT INTO subscriptions (username,url,owner,category) VALUES (\"" . mysql_real_escape_string($username) . "\", \"" . mysql_real_escape_string($header['Subscription']) . "\", \"true\", \"" . mysql_real_escape_string($header['Category']) . "\")"; + $inssub = "INSERT INTO subscriptions (username,url,owner,category) VALUES (\"" . mysql_real_escape_string($username) . "\", \"" . mysql_real_escape_string($headerMap['Subscription']) . "\", \"true\", \"" . mysql_real_escape_string($headerMap['Category']) . "\")"; $inssub2 = mysql_query($inssub); $delcode = "DELETE FROM pending2 WHERE username = \"" . mysql_real_escape_string($username) . "\" AND url = \"" . mysql_real_escape_string($url) . "\""; diff --git a/central/trunk/mansub.php b/central/trunk/mansub.php index 3a2e2d0..b36966f 100644 --- a/central/trunk/mansub.php +++ b/central/trunk/mansub.php @@ -14,7 +14,7 @@ if (isset($_SESSION['username'])) $i=0; for ($i=0;$i<$subs['size'];$i++) { - $template->adds_block('SUBSCRIPTION', array( 'URL' => $subs[$i], + $template->adds_block('SUBSCRIPTIONS', array( 'URL' => $subs[$i], 'ID' => $i, 'EVEN' => (($i % 2 == 0) ? " CLASS=\"even\"" : ""))); } -- cgit 1.4.1