http://www.atutor.ca/atutor/mantis/view.php?id=2628
authorjoel kronenberg <joel.kronenberg@utoronto.ca>
Mon, 10 Jul 2006 17:57:47 +0000 (17:57 -0000)
committerjoel kronenberg <joel.kronenberg@utoronto.ca>
Mon, 10 Jul 2006 17:57:47 +0000 (17:57 -0000)
docs/documentation/admin/en/index.php [new file with mode: 0644]
docs/documentation/common/frame_header.php
docs/documentation/common/text.php
docs/documentation/common/vitals.inc.php
docs/documentation/general/en/index.php [new file with mode: 0644]
docs/documentation/index.php
docs/documentation/index/en/index.php [new file with mode: 0644]
docs/documentation/index/fr/index.php [new file with mode: 0644]
docs/documentation/index/index.php [new file with mode: 0644]
docs/documentation/index_list.php
docs/documentation/instructor/en/index.php [new file with mode: 0644]

diff --git a/docs/documentation/admin/en/index.php b/docs/documentation/admin/en/index.php
new file mode 100644 (file)
index 0000000..ca04c93
--- /dev/null
@@ -0,0 +1,17 @@
+<?php
+/************************************************************************/
+/* ATutor                                                                                                                              */
+/************************************************************************/
+/* Copyright (c) 2002-2006 by Greg Gay, Joel Kronenberg                    */
+/* Adaptive Technology Resource Centre / University of Toronto                 */
+/* http://atutor.ca                                                                                                            */
+/*                                                                                                                                             */
+/* This program is free software. You can redistribute it and/or               */
+/* modify it under the terms of the GNU General Public License                 */
+/* as published by the Free Software Foundation.                                               */
+/************************************************************************/
+// $Id: index.php 5866 2005-12-15 16:16:03Z joel $
+
+header('Location: ../index.php'); // no need for english
+exit;
+?>
\ No newline at end of file
index 8a94e86..59a4d77 100644 (file)
@@ -59,7 +59,7 @@ if (top.name == 'popup') {
 // -->\r
 </script>\r
 \r
-<a href="../index_list.php" target="_top"><?php get_text('return_to_handbook'); ?></a> | \r
+<a href="../index/<?php echo $req_lang; ?>" target="_top"><?php get_text('return_to_handbook'); ?></a> | \r
 \r
 <input type="text" name="query" /> <input type="submit" name="search" value="<?php get_text('search'); ?>" /> |  <a href="print.php?<?php echo $section; ?>" target="_top"><?php get_text('print_version'); ?></a>\r
                        <script type="text/javascript">\r
index aa301e1..3e857ce 100644 (file)
@@ -20,7 +20,7 @@ $text['doc_admin'] = 'Administrator Documentation';
 $text['doc_dev'] = 'Developer Documentation';\r
 $text['doc_instructor'] = 'Instructor Documentation';\r
 $text['doc_mods'] = 'Module Development Documentation';\r
-$text['doc_notes_enabled'] = 'User contributed notes is <em>enabled</em>. <a href="index_list.php?login">Administrator Login</a>.';\r
+$text['doc_notes_enabled'] = 'User contributed notes is <em>enabled</em>. <a href="index.php?login">Administrator Login</a>.';\r
 $text['doc_title'] = 'ATutor 1.5.3 Documentation';\r
 $text['doc_welcome'] = 'Welcome to the official ATutor Handbook!';\r
 $text['doc_unapproved_notes'] = 'Un-Approved User Contributed Notes';\r
@@ -29,7 +29,7 @@ $text['doc_approve'] = 'Approve';
 $text['doc_delete'] = 'Delete';\r
 $text['doc_delete_confirm'] = 'Are you sure you want to delete this note?';\r
 $text['doc_no_notes'] = 'There are no un-approved user contributed notes.';\r
-$text['doc_logged_in'] = 'Logged in as notes moderator. <a href="index_list.php?logout">Log-out</a>.';\r
+$text['doc_logged_in'] = 'Logged in as notes moderator. <a href="index.php?logout">Log-out</a>.';\r
 $text['user_contributed_notes'] = 'User Contributed Notes';\r
 $text['no_notes_on_page'] = 'There are no user contributed notes for this page.';\r
 $text['delete'] = 'Delete';\r
index 76fb79e..f306d3f 100644 (file)
@@ -45,6 +45,7 @@ function get_text($var, $return = FALSE) {
        global $req_lang, $lang, $section;\r
 \r
        static $req_lang_text, $lang_text;\r
+\r
        if (!isset($req_lang_text) && ($req_lang != 'en')) {\r
                $text = array();\r
                if (file_exists(dirname(__FILE__) . '/'.$req_lang.'/text.php')) {\r
@@ -98,7 +99,7 @@ session_start();
 // $req_lang is the language we're requesting\r
 \r
 \r
-$_available_sections = array('admin' => 'admin', 'instructor' => 'instructor', 'general' => 'general');\r
+$_available_sections = array('admin' => 'admin', 'instructor' => 'instructor', 'general' => 'general', 'index' => 'index');\r
 $available_languages = array('en' => 'en', 'fr'=>'fr');\r
 \r
 $parts = pathinfo($_SERVER['PHP_SELF']);\r
@@ -117,17 +118,19 @@ if (isset($_available_sections[$second_last_dir_name])) {
        $section = $last_dir_name;\r
        $rel_path = '../';\r
        get_available_languages($section);\r
+\r
        foreach ($_GET as $lang_name => $garbage) {\r
                if (isset($available_languages[$lang_name])) {\r
                        $lang = $req_lang = $lang_name;\r
                        break;\r
                }\r
        }\r
-       if (isset($_SESSION['lang']) && isset($available_languages[$_SESSION['lang']])) {\r
+       if (!$lang && !$req_lang && isset($_SESSION['lang']) && isset($available_languages[$_SESSION['lang']])) {\r
                $lang = $req_lang = $_SESSION['lang'];\r
-       } else {\r
+       } else if (!$lang && !$req_lang) {\r
                $lang = $req_lang = 'en';\r
        }\r
+\r
 } else {\r
        foreach ($_available_sections as $section_name) {\r
                if (isset($_GET[$section_name])) {\r
diff --git a/docs/documentation/general/en/index.php b/docs/documentation/general/en/index.php
new file mode 100644 (file)
index 0000000..ca04c93
--- /dev/null
@@ -0,0 +1,17 @@
+<?php
+/************************************************************************/
+/* ATutor                                                                                                                              */
+/************************************************************************/
+/* Copyright (c) 2002-2006 by Greg Gay, Joel Kronenberg                    */
+/* Adaptive Technology Resource Centre / University of Toronto                 */
+/* http://atutor.ca                                                                                                            */
+/*                                                                                                                                             */
+/* This program is free software. You can redistribute it and/or               */
+/* modify it under the terms of the GNU General Public License                 */
+/* as published by the Free Software Foundation.                                               */
+/************************************************************************/
+// $Id: index.php 5866 2005-12-15 16:16:03Z joel $
+
+header('Location: ../index.php'); // no need for english
+exit;
+?>
\ No newline at end of file
index 08037c0..bcceb99 100644 (file)
@@ -21,7 +21,7 @@ if (substr($parts['dirname'], -5) == 'admin') {
 } else if (substr($parts['dirname'], -7) == 'general') {
        $section = 'general';
 } else {
-       header('Location: index_list.php');
+       header('Location: index/index.php');
        exit;
 }
 
diff --git a/docs/documentation/index/en/index.php b/docs/documentation/index/en/index.php
new file mode 100644 (file)
index 0000000..ca04c93
--- /dev/null
@@ -0,0 +1,17 @@
+<?php
+/************************************************************************/
+/* ATutor                                                                                                                              */
+/************************************************************************/
+/* Copyright (c) 2002-2006 by Greg Gay, Joel Kronenberg                    */
+/* Adaptive Technology Resource Centre / University of Toronto                 */
+/* http://atutor.ca                                                                                                            */
+/*                                                                                                                                             */
+/* This program is free software. You can redistribute it and/or               */
+/* modify it under the terms of the GNU General Public License                 */
+/* as published by the Free Software Foundation.                                               */
+/************************************************************************/
+// $Id: index.php 5866 2005-12-15 16:16:03Z joel $
+
+header('Location: ../index.php'); // no need for english
+exit;
+?>
\ No newline at end of file
diff --git a/docs/documentation/index/fr/index.php b/docs/documentation/index/fr/index.php
new file mode 100644 (file)
index 0000000..2656b1f
--- /dev/null
@@ -0,0 +1,22 @@
+<?php
+/************************************************************************/
+/* ATutor                                                                                                                              */
+/************************************************************************/
+/* Copyright (c) 2002-2006 by Greg Gay, Joel Kronenberg                    */
+/* Adaptive Technology Resource Centre / University of Toronto                 */
+/* http://atutor.ca                                                                                                            */
+/*                                                                                                                                             */
+/* This program is free software. You can redistribute it and/or               */
+/* modify it under the terms of the GNU General Public License                 */
+/* as published by the Free Software Foundation.                                               */
+/************************************************************************/
+// $Id: index.php 5866 2005-12-15 16:16:03Z joel $
+
+$parts = pathinfo($_SERVER['PHP_SELF']);
+
+$dir_parts = explode('/', $parts['dirname']);
+$last_dir_name = end($dir_parts);
+
+header('Location: ../index.php?' . $last_dir_name);
+exit;
+?>
\ No newline at end of file
diff --git a/docs/documentation/index/index.php b/docs/documentation/index/index.php
new file mode 100644 (file)
index 0000000..b7ef5b4
--- /dev/null
@@ -0,0 +1,163 @@
+<?php\r
+require(dirname(__FILE__) .'/../common/vitals.inc.php');\r
+\r
+// using 401 authentication\r
+if (isset($_GET['login'])) {\r
+       if (!isset($_SERVER['PHP_AUTH_USER'])) {\r
+               header('WWW-Authenticate: Basic realm="Administrator Login"');\r
+               header('HTTP/1.0 401 Unauthorized');\r
+               echo 'Wrong username/password combination.';\r
+               exit;\r
+       } else {\r
+               $_POST['username'] = $_SERVER['PHP_AUTH_USER'];\r
+               $_POST['password'] = $_SERVER['PHP_AUTH_PW'];\r
+               $_POST['submit']   = true;\r
+       }\r
+       unset($_SERVER['PHP_AUTH_USER']);\r
+       unset($_SERVER['PHP_AUTH_PW']);\r
+}\r
+\r
+$config_location = '../../include/config.inc.php';\r
+if (is_file($config_location) && is_readable($config_location)) {\r
+       require($config_location);\r
+       $db = mysql_connect(DB_HOST . ':' . DB_PORT, DB_USER, DB_PASSWORD);\r
+       mysql_select_db(DB_NAME, $db);\r
+\r
+       // check atutor config table to see if handbook notes is enabled.\r
+       $sql    = "SELECT value FROM ".TABLE_PREFIX."config WHERE name='user_notes'";\r
+       $result = @mysql_query($sql, $db);\r
+       if (($row = mysql_fetch_assoc($result)) && $row['value']) {\r
+               define('AT_HANDBOOK_ENABLE', true);\r
+               $enable_user_notes = true;\r
+       }\r
+       define('AT_HANDBOOK_DB_TABLE_PREFIX', TABLE_PREFIX);\r
+\r
+       if (isset($_POST['submit'])) {\r
+               // try to validate $_POST\r
+               // authenticate against the ATutor database if a connection can be made\r
+               $_POST['username'] = addslashes($_POST['username']);\r
+               $_POST['password'] = addslashes($_POST['password']);\r
+                       \r
+               if (!$db) {\r
+                       $db = @mysql_connect(AT_HANDBOOK_DB_HOST . ':' . AT_HANDBOOK_DB_PORT, AT_HANDBOOK_DB_USER, AT_HANDBOOK_DB_PASSWORD);\r
+                       if (@mysql_select_db(AT_HANDBOOK_DB_DATABASE, $db)) {\r
+                               $enable_user_notes = true;\r
+                       }\r
+               }\r
+                       \r
+               // check if it's an admin login.\r
+               $sql = "SELECT login, `privileges` FROM ".TABLE_PREFIX."admins WHERE login='$_POST[username]' AND PASSWORD(password)=PASSWORD('$_POST[password]') AND `privileges`>0";\r
+               $result = mysql_query($sql, $db);\r
+               if ($row = mysql_fetch_assoc($result)) {\r
+                       $_SESSION['handbook_admin'] = true;\r
+                       header('Location: '.$_SERVER['PHP_SELF']);\r
+                       exit;\r
+               }\r
+       } else if (isset($_GET['logout'])) {\r
+               header('WWW-Authenticate: Basic realm="Administrator Login"');\r
+               header('HTTP/1.0 401 Unauthorized');\r
+\r
+               unset($_SERVER['PHP_AUTH_USER']);\r
+               unset($_SERVER['PHP_AUTH_PW']);\r
+               unset($_SESSION['handbook_admin']);\r
+               session_write_close();\r
+               header('Location: '.$_SERVER['PHP_SELF']);\r
+               exit;\r
+       }\r
+}\r
+\r
+if (!defined('AT_HANDBOOK_ENABLE')) {\r
+       // use local config file\r
+       require('../config.inc.php');\r
+\r
+       if (isset($_POST['submit'])) {\r
+               // try to validate $_POST\r
+               if (($_POST['username'] == AT_HANDBOOK_ADMIN_USERNAME) && ($_POST['password'] == AT_HANDBOOK_ADMIN_PASSWORD)) {\r
+                       $_SESSION['handbook_admin'] = true;\r
+                       header('Location: '.$_SERVER['PHP_SELF']);\r
+                       exit;\r
+               }\r
+       } else if (key($_GET) == 'logout') {\r
+               header('WWW-Authenticate: Basic realm="Administrator Login"');\r
+               header('HTTP/1.0 401 Unauthorized');\r
+\r
+               unset($_SERVER['PHP_AUTH_USER']);\r
+               unset($_SERVER['PHP_AUTH_PW']);\r
+               unset($_SESSION['handbook_admin']);\r
+               session_write_close();\r
+               header('Location: '.$_SERVER['PHP_SELF']);\r
+               exit;\r
+       }\r
+}\r
+\r
+if (!$db && defined('AT_HANDBOOK_ENABLE') && AT_HANDBOOK_ENABLE) {\r
+       $db = @mysql_connect(AT_HANDBOOK_DB_HOST . ':' . AT_HANDBOOK_DB_PORT, AT_HANDBOOK_DB_USER, AT_HANDBOOK_DB_PASSWORD);\r
+       @mysql_select_db(AT_HANDBOOK_DB_DATABASE, $db);\r
+       $enable_user_notes = true;\r
+}\r
+?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict //EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">\r
+<html lang="<?php if ($req_lang) { echo $req_lang; } else { echo 'dp'; } ?>">\r
+<head>\r
+       <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />\r
+       <title><?php get_text('doc_title'); ?></title>\r
+       <link rel="stylesheet" href="../common/styles.css" type="text/css" />\r
+</head>\r
+<body>\r
+<?php if ($missing_lang): ?>\r
+       <div style="margin: 20px auto; border: 1px solid #aaf; padding: 4px; text-align: center; background-color: #eef;">\r
+               <?php get_text('page_not_translated'); ?>\r
+       </div>\r
+<?php endif; ?>\r
+\r
+<h1><?php get_text('doc_title'); ?></h1>\r
+<p><?php get_text('doc_welcome'); ?></p>\r
+\r
+       <ol>\r
+               <li><a href="../general/<?php echo $req_lang; ?>"><?php get_text('doc_user'); ?></a></li>\r
+               <li><a href="../admin/<?php echo $req_lang; ?>"><?php get_text('doc_admin'); ?></a></li>\r
+               <li><a href="../instructor/<?php echo $req_lang; ?>"><?php get_text('doc_instructor'); ?></a></li>\r
+               <li><a href="../developer/guidelines.html"><?php get_text('doc_dev'); ?></a></li>\r
+               <li><a href="../developer/modules.html"><?php get_text('doc_mods'); ?></a></li>\r
+       </ol>\r
+\r
+       <ol>\r
+               <li><a href="http://www.atutor.ca" target="new">atutor.ca</a></li>\r
+               <li><a href="http://www.atutor.ca/forums/" target="new">atutor.ca/forums/</a></li>\r
+               <li><a href="http://www.atutor.ca/atutor/docs/index.php" target="new">atutor.ca/atutor/docs/</a></li>\r
+       </ol>\r
+\r
+<?php if ($enable_user_notes && (!isset($_SESSION['handbook_admin']) || (isset($_SESSION['handbook_admin']) && !$_SESSION['handbook_admin']))): ?>\r
+       <div style="text-align: right;">\r
+               <p><?php get_text('doc_notes_enabled');  ?></p>\r
+       </div>\r
+<?php elseif ($enable_user_notes): ?>\r
+\r
+       <p><?php get_text('doc_logged_in'); ?></p>\r
+\r
+       <?php\r
+               $sql = "SELECT note_id, date, section, page, email, note FROM ".AT_HANDBOOK_DB_TABLE_PREFIX."handbook_notes WHERE approved=0 ORDER BY date DESC";\r
+               $result = mysql_query($sql, $db);\r
+       ?>\r
+       <div class="add-note">\r
+               <h3><?php get_text('doc_unapproved_notes'); ?></h3>\r
+       </div>\r
+\r
+       <?php if ($result && (mysql_num_rows($result) > 0)): ?>\r
+               <?php while ($row = mysql_fetch_assoc($result)): ?>\r
+                       <div class="note">\r
+                               <h5><?php echo $row['date']; ?>\r
+                                       <a href="../approve_note.php?id=<?php echo $row['note_id']; ?>" onclick="return confirm('<?php echo get_text('doc_approved_confirm'); ?>');"><?php  get_text('doc_approve'); ?></a> | \r
+                                       <a href="../delete_note.php?id=<?php echo $row['note_id']; ?>" onclick="return confirm('<?php echo get_text('doc_delete_confirm'); ?>');"><?php get_text('doc_delete'); ?></a>\r
+                               </h5>\r
+                               <h4><?php echo $row['email'];?></h4>\r
+                               <p><?php echo nl2br($row['note']); ?></p>\r
+                       </div>\r
+               <?php endwhile; ?>\r
+       <?php else: ?>\r
+               <div class="note"><?php get_text('doc_no_notes'); ?></div>\r
+       <?php endif; ?>\r
+\r
+<?php endif; ?>\r
+\r
+</body>\r
+</html>
\ No newline at end of file
index 4fd4198..37c544d 100644 (file)
@@ -1,172 +1,4 @@
 <?php\r
-require(dirname(__FILE__) .'/common/vitals.inc.php');\r
-\r
-if($_GET['lang']){\r
-       $req_lang = stripslashes($_GET['lang']);\r
-       session_start();\r
-       $_SESSION['lang'] = $req_lang;\r
-       $lang = $req_lang;\r
-       $_available_sections = array('none' => '');\r
-}else if($_SESSION['lang']){\r
-       $req_lang = $_SESSION['lang'];\r
-}\r
-// using 401 authentication\r
-if (key($_GET) == 'login') {\r
-       if (!isset($_SERVER['PHP_AUTH_USER'])) {\r
-               header('WWW-Authenticate: Basic realm="Administrator Login"');\r
-               header('HTTP/1.0 401 Unauthorized');\r
-               echo 'Wrong username/password combination.';\r
-               exit;\r
-       } else {\r
-               $_POST['username'] = $_SERVER['PHP_AUTH_USER'];\r
-               $_POST['password'] = $_SERVER['PHP_AUTH_PW'];\r
-               $_POST['submit']   = true;\r
-       }\r
-       unset($_SERVER['PHP_AUTH_USER']);\r
-       unset($_SERVER['PHP_AUTH_PW']);\r
-}\r
-\r
-$config_location = '../include/config.inc.php';\r
-if (is_file($config_location) && is_readable($config_location)) {\r
-       require($config_location);\r
-       $db = mysql_connect(DB_HOST . ':' . DB_PORT, DB_USER, DB_PASSWORD);\r
-       mysql_select_db(DB_NAME, $db);\r
-\r
-       // check atutor config table to see if handbook notes is enabled.\r
-       $sql    = "SELECT value FROM ".TABLE_PREFIX."config WHERE name='user_notes'";\r
-       $result = @mysql_query($sql, $db);\r
-       if (($row = mysql_fetch_assoc($result)) && $row['value']) {\r
-               define('AT_HANDBOOK_ENABLE', true);\r
-               $enable_user_notes = true;\r
-       }\r
-       define('AT_HANDBOOK_DB_TABLE_PREFIX', TABLE_PREFIX);\r
-\r
-       if (isset($_POST['submit'])) {\r
-               // try to validate $_POST\r
-               // authenticate against the ATutor database if a connection can be made\r
-               $_POST['username'] = addslashes($_POST['username']);\r
-               $_POST['password'] = addslashes($_POST['password']);\r
-                       \r
-               if (!$db) {\r
-                       $db = @mysql_connect(AT_HANDBOOK_DB_HOST . ':' . AT_HANDBOOK_DB_PORT, AT_HANDBOOK_DB_USER, AT_HANDBOOK_DB_PASSWORD);\r
-                       if (@mysql_select_db(AT_HANDBOOK_DB_DATABASE, $db)) {\r
-                               $enable_user_notes = true;\r
-                       }\r
-               }\r
-                       \r
-               // check if it's an admin login.\r
-               $sql = "SELECT login, `privileges` FROM ".TABLE_PREFIX."admins WHERE login='$_POST[username]' AND PASSWORD(password)=PASSWORD('$_POST[password]') AND `privileges`>0";\r
-               $result = mysql_query($sql, $db);\r
-               if ($row = mysql_fetch_assoc($result)) {\r
-                       $_SESSION['handbook_admin'] = true;\r
-                       header('Location: '.$_SERVER['PHP_SELF']);\r
-                       exit;\r
-               }\r
-       } else if (isset($_GET['logout'])) {\r
-               header('WWW-Authenticate: Basic realm="Administrator Login"');\r
-               header('HTTP/1.0 401 Unauthorized');\r
-\r
-               unset($_SERVER['PHP_AUTH_USER']);\r
-               unset($_SERVER['PHP_AUTH_PW']);\r
-               unset($_SESSION['handbook_admin']);\r
-               session_write_close();\r
-               header('Location: '.$_SERVER['PHP_SELF']);\r
-               exit;\r
-       }\r
-}\r
-\r
-if (!defined('AT_HANDBOOK_ENABLE')) {\r
-       // use local config file\r
-       require('./config.inc.php');\r
-\r
-       if (isset($_POST['submit'])) {\r
-               // try to validate $_POST\r
-               if (($_POST['username'] == AT_HANDBOOK_ADMIN_USERNAME) && ($_POST['password'] == AT_HANDBOOK_ADMIN_PASSWORD)) {\r
-                       $_SESSION['handbook_admin'] = true;\r
-                       header('Location: '.$_SERVER['PHP_SELF']);\r
-                       exit;\r
-               }\r
-       } else if (key($_GET) == 'logout') {\r
-               header('WWW-Authenticate: Basic realm="Administrator Login"');\r
-               header('HTTP/1.0 401 Unauthorized');\r
-\r
-               unset($_SERVER['PHP_AUTH_USER']);\r
-               unset($_SERVER['PHP_AUTH_PW']);\r
-               unset($_SESSION['handbook_admin']);\r
-               session_write_close();\r
-               header('Location: '.$_SERVER['PHP_SELF']);\r
-               exit;\r
-       }\r
-}\r
-\r
-if (!$db && defined('AT_HANDBOOK_ENABLE') && AT_HANDBOOK_ENABLE) {\r
-       $db = @mysql_connect(AT_HANDBOOK_DB_HOST . ':' . AT_HANDBOOK_DB_PORT, AT_HANDBOOK_DB_USER, AT_HANDBOOK_DB_PASSWORD);\r
-       @mysql_select_db(AT_HANDBOOK_DB_DATABASE, $db);\r
-       $enable_user_notes = true;\r
-}\r
-?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict //EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">\r
-<html lang="<?php if ($req_lang) { echo $req_lang; } else { echo 'dp'; } ?>">\r
-<head>\r
-       <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />\r
-       <title><?php get_text('doc_title'); ?></title>\r
-       <link rel="stylesheet" href="common/styles.css" type="text/css" />\r
-</head>\r
-<body>\r
-<?php if ($missing_lang): ?>\r
-       <div style="margin: 20px auto; border: 1px solid #aaf; padding: 4px; text-align: center; background-color: #eef;">\r
-               <?php get_text('page_not_translated'); ?>\r
-       </div>\r
-<?php endif; ?>\r
-\r
-<h1><?php get_text('doc_title'); ?></h1>\r
-<p><?php get_text('doc_welcome'); ?></p>\r
-\r
-       <ol>\r
-               <li><a href="general/"><?php get_text('doc_user'); ?></a></li>\r
-               <li><a href="admin/"><?php get_text('doc_admin'); ?></a></li>\r
-               <li><a href="instructor/"><?php get_text('doc_instructor'); ?></a></li>\r
-               <li><a href="developer/guidelines.html"><?php get_text('doc_dev'); ?></a></li>\r
-               <li><a href="developer/modules.html"><?php get_text('doc_mods'); ?></a></li>\r
-       </ol>\r
-\r
-       <ol>\r
-               <li><a href="http://www.atutor.ca" target="new">atutor.ca</a></li>\r
-               <li><a href="http://www.atutor.ca/forums/" target="new">atutor.ca/forums/</a></li>\r
-               <li><a href="http://www.atutor.ca/atutor/docs/index.php" target="new">atutor.ca/atutor/docs/</a></li>\r
-       </ol>\r
-\r
-<?php if ($enable_user_notes && (!isset($_SESSION['handbook_admin']) || (isset($_SESSION['handbook_admin']) && !$_SESSION['handbook_admin']))): ?>\r
-       <div style="text-align: right;">\r
-               <p><?php get_text('doc_notes_enabled');  ?></p>\r
-       </div>\r
-<?php elseif ($enable_user_notes): ?>\r
-\r
-       <p><?php get_text('doc_logged_in'); ?></p>\r
-\r
-       <?php\r
-               $sql = "SELECT note_id, date, section, page, email, note FROM ".AT_HANDBOOK_DB_TABLE_PREFIX."handbook_notes WHERE approved=0 ORDER BY date DESC";\r
-               $result = mysql_query($sql, $db);\r
-       ?>\r
-       <div class="add-note">\r
-               <h3><?php get_text('doc_unapproved_notes'); ?></h3>\r
-       </div>\r
-\r
-       <?php if ($result && (mysql_num_rows($result) > 0)): ?>\r
-               <?php while ($row = mysql_fetch_assoc($result)): ?>\r
-                       <div class="note">\r
-                               <h5><?php echo $row['date']; ?>\r
-                                       <a href="approve_note.php?id=<?php echo $row['note_id']; ?>" onclick="return confirm('<?php echo get_text('doc_approved_confirm'); ?>');"><?php  get_text('doc_approve'); ?></a> | \r
-                                       <a href="delete_note.php?id=<?php echo $row['note_id']; ?>" onclick="return confirm('<?php echo get_text('doc_delete_confirm'); ?>');"><?php get_text('doc_delete'); ?></a>\r
-                               </h5>\r
-                               <h4><?php echo $row['email'];?></h4>\r
-                               <p><?php echo nl2br($row['note']); ?></p>\r
-                       </div>\r
-               <?php endwhile; ?>\r
-       <?php else: ?>\r
-               <div class="note"><?php get_text('doc_no_notes'); ?></div>\r
-       <?php endif; ?>\r
-\r
-<?php endif; ?>\r
-\r
-</body>\r
-</html>
\ No newline at end of file
+header('Location: index/index.php?'.$_GET['lang']);\r
+exit;\r
+?>
\ No newline at end of file
diff --git a/docs/documentation/instructor/en/index.php b/docs/documentation/instructor/en/index.php
new file mode 100644 (file)
index 0000000..ca04c93
--- /dev/null
@@ -0,0 +1,17 @@
+<?php
+/************************************************************************/
+/* ATutor                                                                                                                              */
+/************************************************************************/
+/* Copyright (c) 2002-2006 by Greg Gay, Joel Kronenberg                    */
+/* Adaptive Technology Resource Centre / University of Toronto                 */
+/* http://atutor.ca                                                                                                            */
+/*                                                                                                                                             */
+/* This program is free software. You can redistribute it and/or               */
+/* modify it under the terms of the GNU General Public License                 */
+/* as published by the Free Software Foundation.                                               */
+/************************************************************************/
+// $Id: index.php 5866 2005-12-15 16:16:03Z joel $
+
+header('Location: ../index.php'); // no need for english
+exit;
+?>
\ No newline at end of file