├── LICENSE ├── app ├── .htaccess ├── cache │ ├── .htaccess │ └── index.html ├── index.html ├── config │ ├── index.html │ ├── hooks.php │ ├── profiler.php │ ├── doctypes.php │ ├── migration.php │ ├── constants.php │ ├── routes.php │ ├── foreign_chars.php │ ├── database.php │ ├── smileys.php │ ├── autoload.php │ └── mimes.php ├── core │ └── index.html ├── errors │ ├── index.html │ ├── error_php.php │ ├── error_general.php │ ├── error_db.php │ └── error_404.php ├── helpers │ └── index.html ├── hooks │ └── index.html ├── logs │ └── index.html ├── models │ ├── index.html │ ├── user_model.php │ ├── list_model.php │ └── task_model.php ├── views │ ├── index.html │ ├── lists │ │ ├── edit_list.php │ │ ├── index.php │ │ ├── add_list.php │ │ └── show.php │ ├── tasks │ │ ├── add_task.php │ │ ├── edit_task.php │ │ └── show.php │ ├── users │ │ ├── login.php │ │ └── register.php │ ├── layouts │ │ └── main.php │ └── home.php ├── controllers │ ├── index.html │ ├── home.php │ ├── users.php │ ├── tasks.php │ └── lists.php ├── libraries │ └── index.html ├── third_party │ └── index.html └── language │ └── english │ └── index.html ├── sys ├── .htaccess ├── fonts │ ├── texb.ttf │ └── index.html ├── index.html ├── core │ ├── index.html │ ├── Model.php │ ├── Controller.php │ ├── Benchmark.php │ ├── Utf8.php │ └── Lang.php ├── database │ ├── index.html │ ├── drivers │ │ ├── index.html │ │ ├── cubrid │ │ │ ├── index.html │ │ │ └── cubrid_utility.php │ │ ├── mssql │ │ │ ├── index.html │ │ │ ├── mssql_utility.php │ │ │ └── mssql_result.php │ │ ├── mysql │ │ │ ├── index.html │ │ │ └── mysql_result.php │ │ ├── mysqli │ │ │ ├── index.html │ │ │ ├── mysqli_utility.php │ │ │ └── mysqli_result.php │ │ ├── oci8 │ │ │ ├── index.html │ │ │ └── oci8_utility.php │ │ ├── odbc │ │ │ ├── index.html │ │ │ └── odbc_utility.php │ │ ├── pdo │ │ │ ├── index.html │ │ │ ├── pdo_utility.php │ │ │ └── pdo_result.php │ │ ├── sqlite │ │ │ ├── index.html │ │ │ ├── sqlite_utility.php │ │ │ └── sqlite_result.php │ │ ├── sqlsrv │ │ │ ├── index.html │ │ │ ├── sqlsrv_utility.php │ │ │ └── sqlsrv_result.php │ │ └── postgre │ │ │ ├── index.html │ │ │ ├── postgre_utility.php │ │ │ └── postgre_result.php │ └── DB.php ├── helpers │ ├── index.html │ ├── language_helper.php │ ├── email_helper.php │ ├── path_helper.php │ ├── xml_helper.php │ ├── number_helper.php │ ├── directory_helper.php │ ├── typography_helper.php │ ├── cookie_helper.php │ ├── array_helper.php │ ├── download_helper.php │ └── security_helper.php ├── language │ ├── index.html │ └── english │ │ ├── index.html │ │ ├── number_lang.php │ │ ├── migration_lang.php │ │ ├── unit_test_lang.php │ │ ├── profiler_lang.php │ │ ├── ftp_lang.php │ │ ├── calendar_lang.php │ │ ├── upload_lang.php │ │ ├── email_lang.php │ │ ├── form_validation_lang.php │ │ ├── imglib_lang.php │ │ ├── db_lang.php │ │ └── date_lang.php └── libraries │ ├── index.html │ ├── Log.php │ └── Cache │ └── drivers │ ├── Cache_dummy.php │ ├── Cache_apc.php │ └── Cache_file.php ├── .htaccess ├── README.md ├── assets └── css │ └── custom.css └── mytodo_ci.sql /LICENSE: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/.htaccess: -------------------------------------------------------------------------------- 1 | Deny from all -------------------------------------------------------------------------------- /sys/.htaccess: -------------------------------------------------------------------------------- 1 | Deny from all -------------------------------------------------------------------------------- /app/cache/.htaccess: -------------------------------------------------------------------------------- 1 | deny from all -------------------------------------------------------------------------------- /sys/fonts/texb.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradtraversy/mytodo_ci/HEAD/sys/fonts/texb.ttf -------------------------------------------------------------------------------- /app/index.html: -------------------------------------------------------------------------------- 1 | 2 |
3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/cache/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/config/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/core/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/errors/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/helpers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/hooks/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/logs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/models/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/views/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/core/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/fonts/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/helpers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/language/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/controllers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/third_party/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /app/language/english/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/language/english/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/cubrid/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/mssql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/mysql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/mysqli/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/oci8/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/odbc/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/pdo/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/sqlite/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/sqlsrv/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /sys/database/drivers/postgre/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |Directory access is forbidden.
8 | 9 | 10 | -------------------------------------------------------------------------------- /.htaccess: -------------------------------------------------------------------------------- 1 | Options +FollowSymLinks 2 | Options -Indexes 3 | DirectoryIndex index.php 4 | RewriteEngine on 5 | RewriteCond $1 !^(index\.php|assets|images|css|js|install|robots\.txt|favicon\.ico) 6 | RewriteCond %{REQUEST_FILENAME} !-f 7 | RewriteCond %{REQUEST_FILENAME} !-d 8 | RewriteRule ^(.*)$ index.php?/$1 [L,QSA] -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | MyTodo v1.0 2 | ========= 3 | 4 | This is a demo application that uses the CodeIgniter framework. Use it as you see fit. 5 | 6 | Note: This versions code may slightly differ from the version I created in the Youtube tutorial. 7 | 8 | I have included a database dump file as well. Just import it via phpmyadmin 9 | -------------------------------------------------------------------------------- /sys/language/english/number_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 |Severity:
6 |Message:
7 |Filename:
8 |Line Number:
9 | 10 | -------------------------------------------------------------------------------- /app/config/hooks.php: -------------------------------------------------------------------------------- 1 | session->userdata('logged_in')){ 5 | //Get the logged in users id 6 | $user_id = $this->session->userdata('user_id'); 7 | //Get all lists from the model 8 | $data['lists'] = $this->List_model->get_all_lists($user_id); 9 | $data['tasks'] = $this->Task_model->get_users_tasks($user_id); 10 | } 11 | 12 | $data['main_content'] = 'home'; 13 | $this->load->view('layouts/main',$data); 14 | } 15 | 16 | } 17 | -------------------------------------------------------------------------------- /app/config/profiler.php: -------------------------------------------------------------------------------- 1 | Edit List 2 | 3 | '); ?> 4 | id.''); ?> 5 | 6 |7 | 8 | 'list_name', 11 | 'value' => $this_list->list_name 12 | ); 13 | ?> 14 | 15 |
16 | 17 |18 | 19 | 'list_body', 22 | 'value' => $this_list->list_body 23 | ); 24 | ?> 25 | 26 |
27 | 28 | 29 | "Update List", 30 | "name" => "submit", 31 | "class" => "btn btn-primary"); ?> 32 |33 | 34 |
35 | -------------------------------------------------------------------------------- /app/views/lists/index.php: -------------------------------------------------------------------------------- 1 |These are your current task lists
12 |To create a new list - Click here -------------------------------------------------------------------------------- /app/views/lists/add_list.php: -------------------------------------------------------------------------------- 1 |
Please fill out the form below to create a new task list
3 | 4 | '); ?> 5 | 6 | 7 |8 | 9 | 'list_name', 12 | 'value' => set_value('list_name') 13 | ); 14 | ?> 15 | 16 |
17 | 18 |19 | 20 | 'list_body', 23 | 'value' => set_value('list_body') 24 | ); 25 | ?> 26 | 27 |
28 | 29 | 30 | "Add List", 31 | "name" => "submit", 32 | "class" => "btn btn-primary"); ?> 33 |34 | 35 |
36 | -------------------------------------------------------------------------------- /app/config/doctypes.php: -------------------------------------------------------------------------------- 1 | '', 5 | 'xhtml1-strict' => '', 6 | 'xhtml1-trans' => '', 7 | 'xhtml1-frame' => '', 8 | 'html5' => '', 9 | 'html4-strict' => '', 10 | 'html4-trans' => '', 11 | 'html4-frame' => '' 12 | ); 13 | 14 | /* End of file doctypes.php */ 15 | /* Location: ./application/config/doctypes.php */ -------------------------------------------------------------------------------- /app/models/user_model.php: -------------------------------------------------------------------------------- 1 | $this->input->post('first_name'), 7 | 'last_name' => $this->input->post('last_name'), 8 | 'email' => $this->input->post('email'), 9 | 'username' => $this->input->post('username'), 10 | 'password' => md5($this->input->post('password')) 11 | ); 12 | 13 | $insert = $this->db->insert('users', $new_member_insert); 14 | return $insert; 15 | } 16 | 17 | 18 | public function login_user($username,$passowrd){ 19 | //Secure password 20 | $enc_password = md5($passowrd); 21 | 22 | //Validate 23 | $this->db->where('username',$username); 24 | $this->db->where('password',$enc_password); 25 | 26 | $result = $this->db->get('users'); 27 | if($result->num_rows() == 1){ 28 | return $result->row(0)->id; 29 | } else { 30 | return false; 31 | } 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /sys/language/english/profiler_lang.php: -------------------------------------------------------------------------------- 1 | Add a Task 2 |List:
3 | 4 | 5 | '); ?> 6 | uri->segment(3).''); ?> 7 | 8 | 9 |10 | 11 | 'task_name', 14 | 'value' => set_value('task_name') 15 | ); 16 | ?> 17 | 18 |
19 | 20 | 21 |22 | 23 | 'task_body', 26 | 'value' => set_value('task_body') 27 | ); 28 | ?> 29 | 30 |
31 | 32 | 33 |34 | 35 | 36 |
37 | 38 | 39 | "Add Task", 40 | "name" => "submit", 41 | "class" => "btn btn-primary"); ?> 42 |43 | 44 |
45 | 46 | -------------------------------------------------------------------------------- /app/views/tasks/edit_task.php: -------------------------------------------------------------------------------- 1 |List:
3 | 4 | 5 | '); ?> 6 | uri->segment(3).''); ?> 7 | 8 | 9 |10 | 11 | 'task_name', 14 | 'value' => $this_task->task_name 15 | ); 16 | ?> 17 | 18 |
19 | 20 | 21 |22 | 23 | 'task_body', 26 | 'value' => $this_task->task_body 27 | ); 28 | ?> 29 | 30 |
31 | 32 | 33 |34 | 35 | 36 |
37 | 38 | 39 | "Update Task", 40 | "name" => "submit", 41 | "class" => "btn btn-primary"); ?> 42 |43 | 44 |
45 | 46 | -------------------------------------------------------------------------------- /sys/language/english/ftp_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |You are logged in as session->userdata('username'); ?>
3 | 4 | 'logout_form', 5 | 'class' => 'form-horizontal'); ?> 6 | 7 | 8 | "Logout", 9 | "name" => "submit", 10 | "class" => "btn btn-primary"); ?> 11 | 12 | 13 | 14 |27 | 28 | 'username', 31 | 'placeholder' => 'Enter Username', 32 | 'style' => 'width:90%', 33 | 'value' => set_value('username') 34 | ); 35 | ?> 36 | 37 |
38 | 39 | 40 |41 | 42 | 'password', 45 | 'placeholder' => 'Enter Password', 46 | 'style' => 'width:90%', 47 | 'value' => set_value('password') 48 | ); 49 | ?> 50 | 51 |
52 |54 | 55 | "Login", 56 | "name" => "submit", 57 | "class" => "btn btn-primary"); ?> 58 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /sys/helpers/number_helper.php: -------------------------------------------------------------------------------- 1 | lang->load('number'); 43 | 44 | if ($num >= 1000000000000) 45 | { 46 | $num = round($num / 1099511627776, $precision); 47 | $unit = $CI->lang->line('terabyte_abbr'); 48 | } 49 | elseif ($num >= 1000000000) 50 | { 51 | $num = round($num / 1073741824, $precision); 52 | $unit = $CI->lang->line('gigabyte_abbr'); 53 | } 54 | elseif ($num >= 1000000) 55 | { 56 | $num = round($num / 1048576, $precision); 57 | $unit = $CI->lang->line('megabyte_abbr'); 58 | } 59 | elseif ($num >= 1000) 60 | { 61 | $num = round($num / 1024, $precision); 62 | $unit = $CI->lang->line('kilobyte_abbr'); 63 | } 64 | else 65 | { 66 | $unit = $CI->lang->line('bytes'); 67 | return number_format($num).' '.$unit; 68 | } 69 | 70 | return number_format($num, $precision).' '.$unit; 71 | } 72 | } 73 | 74 | 75 | /* End of file number_helper.php */ 76 | /* Location: ./system/helpers/number_helper.php */ -------------------------------------------------------------------------------- /app/views/layouts/main.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |