removed mods directory from the ATutor codebase
[atutor.git] / mods / mahara / cookie.php
diff --git a/mods/mahara/cookie.php b/mods/mahara/cookie.php
deleted file mode 100644 (file)
index 04085b5..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php\r
-/*\r
-    Called by index.php when user opens a new window.\r
-    To avoid conflicting sessions between ATutor and Mahara,\r
-    we are passing information through temporary cookies.\r
-    This page simply acts as a bridge between ATutor and Mahara\r
-    by using the ATutor session to read the user login from the \r
-    database, then setting the cookies and forwarding to\r
-    the login script (mahara_login.php).\r
-\r
-    by: Boon-Hau Teh\r
-*/\r
-\r
-$_user_location        = 'public';\r
-\r
-define('AT_INCLUDE_PATH', '../../include/');\r
-require (AT_INCLUDE_PATH.'vitals.inc.php');\r
-\r
-// Read login info for Mahara\r
-$sql    = "SELECT username, SHA1(password) FROM ".TABLE_PREFIX."mahara WHERE at_login='".$_SESSION['login']."'";\r
-$result = mysql_query($sql, $db);\r
-\r
-if ($row = @mysql_fetch_array($result)) {\r
-    ATutor.setcookie("ATutor_Mahara[at_login]", $_SESSION['login'], time()+1200); \r
-    ATutor.setcookie("ATutor_Mahara[username]", $row[0], time()+1200); \r
-    ATutor.setcookie("ATutor_Mahara[password]", $row[1], time()+1200); \r
-\r
-    if (function_exists('url_rewrite')) {   // if "pretty url" feature supported (from ATutor 1.6.1)\r
-        $url = url_rewrite('mods/mahara/mahara_login.php', AT_PRETTY_URL_IS_HEADER);\r
-    } else {\r
-        $url = AT_BASE_HREF.'mods/mahara/mahara_login.php';\r
-    }\r
-\r
-    // proceed to login script\r
-    header('Location: '.$url);\r
-}\r
-\r
-?>
\ No newline at end of file