remove old readme
[atutor.git] / install / install.php
1 <?php
2 /************************************************************************/
3 /* ATutor                                                                                                                               */
4 /************************************************************************/
5 /* Copyright (c) 2002-2010                                              */
6 /* http://atutor.ca                                                     */
7 /* This program is free software. You can redistribute it and/or        */
8 /* modify it under the terms of the GNU General Public License          */
9 /* as published by the Free Software Foundation.                        */
10 /************************************************************************/
11 // $Id$
12
13 // Be careful at modifying AT_INCLUDE_PATH constant which is used by 
14 // get_atutor_installation_path() @ common.inc.php. Must make sure the 
15 // function doesn't get broken at its modification.
16 define('AT_INCLUDE_PATH', 'include/');
17 require(AT_INCLUDE_PATH.'common.inc.php');
18
19 if (!$new_version = $_POST['new_version']) {
20         $new_version = $_POST['step2']['new_version'];
21 }
22
23 $step = intval($_POST['step']);
24
25 if ($step == 0) {
26         $step = 1;
27 }
28
29 if ($_POST['submit'] == 'I Disagree'){
30         Header ("Location: index.php");
31 }
32
33 require(AT_INCLUDE_PATH.'header.php');
34
35 /* agree to terms of use */
36 if ($step == 1) {
37         require(AT_INCLUDE_PATH.'step1.php');
38 }
39
40 /* db */
41 if ($step == 2) {
42         require(AT_INCLUDE_PATH.'step2.php');
43 }
44
45 /* preferences */
46 if ($step == 3) {       
47         require(AT_INCLUDE_PATH.'step3.php');
48 }
49
50 /* personal account + welcome course */
51 //if ($step == 4) {     
52         //require(AT_INCLUDE_PATH.'step4.php');
53 //}
54
55 /* content directory */
56 if ($step == 4) {
57         require(AT_INCLUDE_PATH.'step5.php');
58 }
59
60 /* directory permissions and generating the config.inc.php file */
61 if ($step == 5) {       
62         require(AT_INCLUDE_PATH.'step6.php');
63 }
64
65 /* anonymous data collection */
66 if ($step == 6) {       
67         require(AT_INCLUDE_PATH.'step7.php');
68 }
69
70 /* done! */
71 if ($step == 7) {       
72         require(AT_INCLUDE_PATH.'step8.php');
73 }
74
75 require(AT_INCLUDE_PATH.'footer.php');
76 ?>