├── system ├── .htaccess ├── fonts │ ├── texb.ttf │ └── index.html ├── index.html ├── core │ ├── index.html │ ├── Model.php │ ├── Controller.php │ └── Benchmark.php ├── database │ ├── index.html │ └── drivers │ │ ├── index.html │ │ ├── pdo │ │ ├── index.html │ │ ├── pdo_utility.php │ │ └── pdo_result.php │ │ ├── cubrid │ │ ├── index.html │ │ └── cubrid_utility.php │ │ ├── mssql │ │ ├── index.html │ │ └── mssql_utility.php │ │ ├── mysql │ │ └── index.html │ │ ├── mysqli │ │ ├── index.html │ │ └── mysqli_utility.php │ │ ├── oci8 │ │ ├── index.html │ │ └── oci8_utility.php │ │ ├── odbc │ │ ├── index.html │ │ └── odbc_utility.php │ │ ├── postgre │ │ ├── index.html │ │ └── postgre_utility.php │ │ ├── sqlite │ │ ├── index.html │ │ └── sqlite_utility.php │ │ └── sqlsrv │ │ ├── index.html │ │ └── sqlsrv_utility.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 ├── application ├── .htaccess ├── cache │ ├── .htaccess │ └── index.html ├── views │ ├── login │ │ ├── v_logout.php │ │ ├── v_noaccess.php │ │ ├── v_login.php │ │ └── v_register.php │ ├── index.html │ ├── admin │ │ ├── v_home.php │ │ └── v_admin_home.php │ ├── template │ │ ├── v_admin_footer.php │ │ ├── v_admin_sidebar.php │ │ └── v_admin_header.php │ └── welcome_message.php ├── index.html ├── core │ └── index.html ├── hooks │ └── index.html ├── logs │ └── 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 ├── errors │ ├── index.html │ ├── error_php.php │ ├── error_db.php │ ├── error_general.php │ └── error_404.php ├── helpers │ └── index.html ├── libraries │ └── index.html ├── models │ ├── index.html │ └── m_user.php ├── controllers │ ├── index.html │ ├── blog.php │ ├── admin.php │ └── login.php ├── third_party │ └── index.html └── language │ └── english │ └── index.html ├── user_guide ├── images │ ├── file.gif │ ├── arrow.gif │ ├── ci_logo.jpg │ ├── folder.gif │ ├── smile.gif │ ├── appflowchart.gif │ ├── ci_quick_ref.png │ ├── transparent.gif │ ├── ci_logo_flame.jpg │ ├── nav_bg_darker.jpg │ ├── reactor-bullet.png │ ├── nav_toggle_darker.jpg │ ├── nav_separator_darker.jpg │ ├── codeigniter_1.7.1_helper_reference.pdf │ ├── codeigniter_1.7.1_helper_reference.png │ ├── codeigniter_1.7.1_library_reference.pdf │ └── codeigniter_1.7.1_library_reference.png ├── nav │ ├── user_guide_menu.js │ ├── hacks.txt │ ├── moo.fx.js │ └── prototype.lite.js ├── general │ ├── quick_reference.html │ ├── requirements.html │ ├── credits.html │ └── creating_drivers.html ├── overview │ ├── index.html │ └── cheatsheets.html ├── doc_style │ └── index.html ├── installation │ ├── upgrade_120.html │ ├── upgrade_210.html │ ├── troubleshooting.html │ └── upgrade_161.html └── helpers │ ├── xml_helper.html │ └── language_helper.html ├── img ├── glyphicons-halflings.png └── glyphicons-halflings-white.png ├── sql └── sql_dump.sql ├── css ├── style.less └── style.css ├── license.txt └── README.md /system/.htaccess: -------------------------------------------------------------------------------- 1 | Deny from all -------------------------------------------------------------------------------- /application/.htaccess: -------------------------------------------------------------------------------- 1 | Deny from all -------------------------------------------------------------------------------- /application/cache/.htaccess: -------------------------------------------------------------------------------- 1 | deny from all -------------------------------------------------------------------------------- /system/fonts/texb.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/system/fonts/texb.ttf -------------------------------------------------------------------------------- /user_guide/images/file.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/file.gif -------------------------------------------------------------------------------- /img/glyphicons-halflings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/img/glyphicons-halflings.png -------------------------------------------------------------------------------- /user_guide/images/arrow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/arrow.gif -------------------------------------------------------------------------------- /user_guide/images/ci_logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/ci_logo.jpg -------------------------------------------------------------------------------- /user_guide/images/folder.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/folder.gif -------------------------------------------------------------------------------- /user_guide/images/smile.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/smile.gif -------------------------------------------------------------------------------- /application/views/login/v_logout.php: -------------------------------------------------------------------------------- 1 |

You have been logged out.

2 | load->view('login/v_login'); ?> 3 | -------------------------------------------------------------------------------- /img/glyphicons-halflings-white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/img/glyphicons-halflings-white.png -------------------------------------------------------------------------------- /user_guide/images/appflowchart.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/appflowchart.gif -------------------------------------------------------------------------------- /user_guide/images/ci_quick_ref.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/ci_quick_ref.png -------------------------------------------------------------------------------- /user_guide/images/transparent.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/transparent.gif -------------------------------------------------------------------------------- /user_guide/images/ci_logo_flame.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/ci_logo_flame.jpg -------------------------------------------------------------------------------- /user_guide/images/nav_bg_darker.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/nav_bg_darker.jpg -------------------------------------------------------------------------------- /user_guide/images/reactor-bullet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/reactor-bullet.png -------------------------------------------------------------------------------- /user_guide/images/nav_toggle_darker.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/nav_toggle_darker.jpg -------------------------------------------------------------------------------- /user_guide/images/nav_separator_darker.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/nav_separator_darker.jpg -------------------------------------------------------------------------------- /user_guide/nav/user_guide_menu.js: -------------------------------------------------------------------------------- 1 | window.onload = function() { 2 | myHeight = new fx.Height('nav', {duration: 400}); 3 | myHeight.hide(); 4 | } -------------------------------------------------------------------------------- /user_guide/images/codeigniter_1.7.1_helper_reference.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/codeigniter_1.7.1_helper_reference.pdf -------------------------------------------------------------------------------- /user_guide/images/codeigniter_1.7.1_helper_reference.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/codeigniter_1.7.1_helper_reference.png -------------------------------------------------------------------------------- /system/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /user_guide/images/codeigniter_1.7.1_library_reference.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/codeigniter_1.7.1_library_reference.pdf -------------------------------------------------------------------------------- /user_guide/images/codeigniter_1.7.1_library_reference.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/howframework/CodeIgniter/HEAD/user_guide/images/codeigniter_1.7.1_library_reference.png -------------------------------------------------------------------------------- /application/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/core/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/fonts/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/cache/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/core/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/hooks/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/logs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/views/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/helpers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/language/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/config/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/errors/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/helpers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/models/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/controllers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/third_party/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/pdo/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/language/english/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/language/english/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/views/login/v_noaccess.php: -------------------------------------------------------------------------------- 1 |

You do not have access or your login has expired.

2 |

Please login or register to proceed.

3 | load->view('login/v_login'); ?> 4 | -------------------------------------------------------------------------------- /system/database/drivers/cubrid/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/mssql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/mysql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/mysqli/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/oci8/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/odbc/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/postgre/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/sqlite/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /system/database/drivers/sqlsrv/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /application/views/admin/v_home.php: -------------------------------------------------------------------------------- 1 | 5 |

Admin

6 |

Congratulations! You are now inside.

7 |

Logout

8 | -------------------------------------------------------------------------------- /user_guide/nav/hacks.txt: -------------------------------------------------------------------------------- 1 | I did the following hack in moo.fx.js: 2 | 3 | At line 79 in the toggle: function() function, I added: 4 | 5 | document.getElementById('nav').style.display = 'block'; 6 | 7 | -- Rick Ellis 8 | 9 | 10 | Also removed fx.Opacity and fx.Height from moo.fx.js -- Pascal -------------------------------------------------------------------------------- /system/language/english/number_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 |

A PHP Error was encountered

4 | 5 |

Severity:

6 |

Message:

7 |

Filename:

8 |

Line Number:

9 | 10 | -------------------------------------------------------------------------------- /application/controllers/blog.php: -------------------------------------------------------------------------------- 1 | load->view('blog/v_blog_home'); 16 | } 17 | 18 | 19 | } 20 | 21 | /* End of file blog.php */ 22 | /* Location: ./application/controllers/blog.php */ -------------------------------------------------------------------------------- /application/views/template/v_admin_footer.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /application/views/admin/v_admin_home.php: -------------------------------------------------------------------------------- 1 | load->view('template/v_admin_header.php'); ?> 2 | 3 |
 
4 |
5 | load->view('template/v_admin_sidebar'); ?> 6 |
7 |
8 |

Welcome . Click here to logout.

9 |
10 | 11 | 12 | load->view('template/v_admin_footer.php'); ?> 13 | -------------------------------------------------------------------------------- /application/config/hooks.php: -------------------------------------------------------------------------------- 1 | 2 | 20 | -------------------------------------------------------------------------------- /application/controllers/admin.php: -------------------------------------------------------------------------------- 1 | load->model('m_user'); 18 | 19 | if ($this->m_user->is_logged_in() === FALSE) { 20 | $this->m_user->remove_pass(); 21 | redirect('login/noaccess'); 22 | } else { 23 | // is_logged_in also put user data in session 24 | $this->data['user'] = $this->session->userdata('user'); 25 | } 26 | 27 | } 28 | 29 | public function index() 30 | { 31 | $this->load->view('admin/v_admin_home', $this->data); 32 | } 33 | 34 | 35 | } 36 | 37 | /* End of file admin.php */ 38 | /* Location: ./application/controllers/admin.php */ -------------------------------------------------------------------------------- /sql/sql_dump.sql: -------------------------------------------------------------------------------- 1 | -- -------------------------------------------------------- 2 | -- Host: localhost 3 | -- Server version: 5.5.16 - MySQL Community Server (GPL) 4 | -- Server OS: Win32 5 | -- HeidiSQL version: 7.0.0.4053 6 | -- Date/time: 2012-05-13 00:15:40 7 | -- -------------------------------------------------------- 8 | 9 | /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; 10 | /*!40101 SET NAMES utf8 */; 11 | /*!40014 SET FOREIGN_KEY_CHECKS=0 */; 12 | 13 | -- Dumping structure for table howframework.users 14 | CREATE TABLE IF NOT EXISTS `users` ( 15 | `id` int(10) NOT NULL AUTO_INCREMENT, 16 | `username` varchar(50) NOT NULL, 17 | `password` varchar(50) NOT NULL, 18 | `email` varchar(100) NOT NULL, 19 | `fullname` varchar(100) NOT NULL, 20 | PRIMARY KEY (`id`), 21 | UNIQUE KEY `username` (`username`), 22 | UNIQUE KEY `email` (`email`) 23 | ) ENGINE=InnoDB DEFAULT CHARSET=utf8; 24 | 25 | -- Data exporting was unselected. 26 | /*!40014 SET FOREIGN_KEY_CHECKS=1 */; 27 | /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; 28 | -------------------------------------------------------------------------------- /application/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 */ -------------------------------------------------------------------------------- /css/style.less: -------------------------------------------------------------------------------- 1 | // LESS Mixins from http://lesselements.com/ 2 | @import "elements.less"; 3 | 4 | body { 5 | padding-top:40px; 6 | 7 | header { 8 | padding:20px 0; 9 | background:#333; 10 | color: #aaa; 11 | border-bottom:#000 solid 1px; 12 | 13 | h1 {color: #eee;} 14 | } 15 | 16 | #body { 17 | #content { 18 | ul { 19 | list-style:none; 20 | margin:0; 21 | padding:30px 0; 22 | 23 | li { 24 | margin-bottom:20px; 25 | 26 | h2 { 27 | line-height:1.2; 28 | margin-bottom:10px; 29 | } 30 | .meta { 31 | margin-bottom:10px; 32 | font-size:12px; 33 | color: #777; 34 | } 35 | .entry {} 36 | a.read-more { 37 | 38 | } 39 | } 40 | } 41 | } 42 | #sidebar { 43 | padding:30px 0; 44 | } 45 | } 46 | footer { 47 | background:#eee; 48 | padding:20px 0; 49 | } 50 | } 51 | 52 | 53 | 54 | 55 | @media (max-width: 767px) { 56 | body { 57 | padding-top:0; 58 | } 59 | } 60 | @media (max-width: 979px) { 61 | body { 62 | padding-top:0; 63 | } 64 | } 65 | @media (min-width: 768px) and (max-width: 979px) { 66 | body { 67 | padding-top:0; 68 | } 69 | } -------------------------------------------------------------------------------- /system/language/english/profiler_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Database Error 5 | 55 | 56 | 57 |
58 |

59 | 60 |
61 | 62 | -------------------------------------------------------------------------------- /application/errors/error_general.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Error 5 | 55 | 56 | 57 |
58 |

59 | 60 |
61 | 62 | -------------------------------------------------------------------------------- /system/core/Model.php: -------------------------------------------------------------------------------- 1 | $key; 52 | } 53 | } 54 | // END Model Class 55 | 56 | /* End of file Model.php */ 57 | /* Location: ./system/core/Model.php */ -------------------------------------------------------------------------------- /application/errors/error_404.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 404 Page Not Found 5 | 55 | 56 | 57 |
58 |

59 | 60 |
61 | 62 | -------------------------------------------------------------------------------- /application/config/migration.php: -------------------------------------------------------------------------------- 1 | migration->latest() this is the version that schema will 21 | | be upgraded / downgraded to. 22 | | 23 | */ 24 | $config['migration_version'] = 0; 25 | 26 | 27 | /* 28 | |-------------------------------------------------------------------------- 29 | | Migrations Path 30 | |-------------------------------------------------------------------------- 31 | | 32 | | Path to your migrations folder. 33 | | Typically, it will be within your application path. 34 | | Also, writing permission is required within the migrations path. 35 | | 36 | */ 37 | $config['migration_path'] = APPPATH . 'migrations/'; 38 | 39 | 40 | /* End of file migration.php */ 41 | /* Location: ./application/config/migration.php */ -------------------------------------------------------------------------------- /css/style.css: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------- 2 | LESS Elements 0.6 3 | --------------------------------------------------- 4 | A set of useful LESS mixins by Dmitry Fadeyev 5 | Special thanks for mixin suggestions to: 6 | Kris Van Herzeele, 7 | Benoit Adam, 8 | Portenart Emile-Victor, 9 | Ryan Faerman 10 | 11 | More info at: http://lesselements.com 12 | -----------------------------------------------------*/ 13 | body { 14 | padding-top: 40px; 15 | } 16 | body header { 17 | padding: 20px 0; 18 | background: #333; 19 | color: #aaa; 20 | border-bottom: #000 solid 1px; 21 | } 22 | body header h1 { 23 | color: #eee; 24 | } 25 | body #body #content ul { 26 | list-style: none; 27 | margin: 0; 28 | padding: 30px 0; 29 | } 30 | body #body #content ul li { 31 | margin-bottom: 20px; 32 | } 33 | body #body #content ul li h2 { 34 | line-height: 1.2; 35 | margin-bottom: 10px; 36 | } 37 | body #body #content ul li .meta { 38 | margin-bottom: 10px; 39 | font-size: 12px; 40 | color: #777; 41 | } 42 | body #body #sidebar { 43 | padding: 30px 0; 44 | } 45 | body footer { 46 | background: #eee; 47 | padding: 20px 0; 48 | } 49 | @media (max-width: 767px) { 50 | body { 51 | padding-top: 0; 52 | } 53 | } 54 | @media (max-width: 979px) { 55 | body { 56 | padding-top: 0; 57 | } 58 | } 59 | @media (min-width: 768px) and (max-width: 979px) { 60 | body { 61 | padding-top: 0; 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /system/helpers/language_helper.php: -------------------------------------------------------------------------------- 1 | lang->line($line); 46 | 47 | if ($id != '') 48 | { 49 | $line = '"; 50 | } 51 | 52 | return $line; 53 | } 54 | } 55 | 56 | // ------------------------------------------------------------------------ 57 | /* End of file language_helper.php */ 58 | /* Location: ./system/helpers/language_helper.php */ -------------------------------------------------------------------------------- /system/language/english/calendar_lang.php: -------------------------------------------------------------------------------- 1 | $class) 45 | { 46 | $this->$var =& load_class($class); 47 | } 48 | 49 | $this->load =& load_class('Loader', 'core'); 50 | 51 | $this->load->initialize(); 52 | 53 | log_message('debug', "Controller Class Initialized"); 54 | } 55 | 56 | public static function &get_instance() 57 | { 58 | return self::$instance; 59 | } 60 | } 61 | // END Controller class 62 | 63 | /* End of file Controller.php */ 64 | /* Location: ./system/core/Controller.php */ -------------------------------------------------------------------------------- /application/config/foreign_chars.php: -------------------------------------------------------------------------------- 1 | 'ae', 12 | '/ö|œ/' => 'oe', 13 | '/ü/' => 'ue', 14 | '/Ä/' => 'Ae', 15 | '/Ü/' => 'Ue', 16 | '/Ö/' => 'Oe', 17 | '/À|Á|Â|Ã|Ä|Å|Ǻ|Ā|Ă|Ą|Ǎ/' => 'A', 18 | '/à|á|â|ã|å|ǻ|ā|ă|ą|ǎ|ª/' => 'a', 19 | '/Ç|Ć|Ĉ|Ċ|Č/' => 'C', 20 | '/ç|ć|ĉ|ċ|č/' => 'c', 21 | '/Ð|Ď|Đ/' => 'D', 22 | '/ð|ď|đ/' => 'd', 23 | '/È|É|Ê|Ë|Ē|Ĕ|Ė|Ę|Ě/' => 'E', 24 | '/è|é|ê|ë|ē|ĕ|ė|ę|ě/' => 'e', 25 | '/Ĝ|Ğ|Ġ|Ģ/' => 'G', 26 | '/ĝ|ğ|ġ|ģ/' => 'g', 27 | '/Ĥ|Ħ/' => 'H', 28 | '/ĥ|ħ/' => 'h', 29 | '/Ì|Í|Î|Ï|Ĩ|Ī|Ĭ|Ǐ|Į|İ/' => 'I', 30 | '/ì|í|î|ï|ĩ|ī|ĭ|ǐ|į|ı/' => 'i', 31 | '/Ĵ/' => 'J', 32 | '/ĵ/' => 'j', 33 | '/Ķ/' => 'K', 34 | '/ķ/' => 'k', 35 | '/Ĺ|Ļ|Ľ|Ŀ|Ł/' => 'L', 36 | '/ĺ|ļ|ľ|ŀ|ł/' => 'l', 37 | '/Ñ|Ń|Ņ|Ň/' => 'N', 38 | '/ñ|ń|ņ|ň|ʼn/' => 'n', 39 | '/Ò|Ó|Ô|Õ|Ō|Ŏ|Ǒ|Ő|Ơ|Ø|Ǿ/' => 'O', 40 | '/ò|ó|ô|õ|ō|ŏ|ǒ|ő|ơ|ø|ǿ|º/' => 'o', 41 | '/Ŕ|Ŗ|Ř/' => 'R', 42 | '/ŕ|ŗ|ř/' => 'r', 43 | '/Ś|Ŝ|Ş|Š/' => 'S', 44 | '/ś|ŝ|ş|š|ſ/' => 's', 45 | '/Ţ|Ť|Ŧ/' => 'T', 46 | '/ţ|ť|ŧ/' => 't', 47 | '/Ù|Ú|Û|Ũ|Ū|Ŭ|Ů|Ű|Ų|Ư|Ǔ|Ǖ|Ǘ|Ǚ|Ǜ/' => 'U', 48 | '/ù|ú|û|ũ|ū|ŭ|ů|ű|ų|ư|ǔ|ǖ|ǘ|ǚ|ǜ/' => 'u', 49 | '/Ý|Ÿ|Ŷ/' => 'Y', 50 | '/ý|ÿ|ŷ/' => 'y', 51 | '/Ŵ/' => 'W', 52 | '/ŵ/' => 'w', 53 | '/Ź|Ż|Ž/' => 'Z', 54 | '/ź|ż|ž/' => 'z', 55 | '/Æ|Ǽ/' => 'AE', 56 | '/ß/'=> 'ss', 57 | '/IJ/' => 'IJ', 58 | '/ij/' => 'ij', 59 | '/Œ/' => 'OE', 60 | '/ƒ/' => 'f' 61 | ); 62 | 63 | /* End of file foreign_chars.php */ 64 | /* Location: ./application/config/foreign_chars.php */ -------------------------------------------------------------------------------- /system/language/english/form_validation_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | HowFrameWork 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 17 | 18 | 19 | 20 | 21 | 54 | 55 |
56 |
57 |
-------------------------------------------------------------------------------- /system/helpers/path_helper.php: -------------------------------------------------------------------------------- 1 | ","\"", "'", "-"), 53 | array("&", "<", ">", """, "'", "-"), 54 | $str); 55 | 56 | // Decode the temp markers back to entities 57 | $str = preg_replace("/$temp(\d+);/","&#\\1;",$str); 58 | 59 | if ($protect_all === TRUE) 60 | { 61 | $str = preg_replace("/$temp(\w+);/","&\\1;", $str); 62 | } 63 | 64 | return $str; 65 | } 66 | } 67 | 68 | // ------------------------------------------------------------------------ 69 | 70 | /* End of file xml_helper.php */ 71 | /* Location: ./system/helpers/xml_helper.php */ -------------------------------------------------------------------------------- /system/language/english/imglib_lang.php: -------------------------------------------------------------------------------- 1 | 6 | load->view('template/v_admin_header.php'); ?> 7 |
8 | 9 |
10 |
11 | Login 12 |
 
13 | 14 | $login_success
" : ''; ?> 15 | $login_error
" : ''; ?> 16 | 17 |
18 | 19 |
20 | 21 | ', '

'); ?> 22 |
23 |
24 |
25 | 26 |
27 | 28 | ', '

'); ?> 29 |
30 |
31 |
32 | 33 |
34 | 35 |
36 |
37 | 38 | 39 | 40 |

Register

41 | 42 |
43 | 44 | load->view('template/v_admin_footer.php'); ?> 45 | -------------------------------------------------------------------------------- /system/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 */ -------------------------------------------------------------------------------- /system/database/drivers/postgre/postgre_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsuported_feature'); 83 | } 84 | } 85 | 86 | 87 | /* End of file postgre_utility.php */ 88 | /* Location: ./system/database/drivers/postgre/postgre_utility.php */ -------------------------------------------------------------------------------- /application/views/welcome_message.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Welcome to CodeIgniter 6 | 7 | 66 | 67 | 68 | 69 |
70 |

Welcome to CodeIgniter!

71 | 72 |
73 |

The page you are looking at is being generated dynamically by CodeIgniter.

74 | 75 |

If you would like to edit this page you'll find it located at:

76 | application/views/welcome_message.php 77 | 78 |

The corresponding controller for this page is found at:

79 | application/controllers/welcome.php 80 | 81 |

If you are exploring CodeIgniter for the very first time, you should start by reading the User Guide.

82 |
83 | 84 | 85 |
86 | 87 | 88 | -------------------------------------------------------------------------------- /system/database/drivers/oci8/oci8_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsuported_feature'); 83 | } 84 | } 85 | 86 | /* End of file oci8_utility.php */ 87 | /* Location: ./system/database/drivers/oci8/oci8_utility.php */ -------------------------------------------------------------------------------- /user_guide/nav/moo.fx.js: -------------------------------------------------------------------------------- 1 | /* 2 | moo.fx, simple effects library built with prototype.js (http://prototype.conio.net). 3 | by Valerio Proietti (http://mad4milk.net) MIT-style LICENSE. 4 | for more info (http://moofx.mad4milk.net). 5 | 10/24/2005 6 | v(1.0.2) 7 | */ 8 | 9 | //base 10 | var fx = new Object(); 11 | fx.Base = function(){}; 12 | fx.Base.prototype = { 13 | setOptions: function(options) { 14 | this.options = { 15 | duration: 500, 16 | onComplete: '' 17 | } 18 | Object.extend(this.options, options || {}); 19 | }, 20 | 21 | go: function() { 22 | this.duration = this.options.duration; 23 | this.startTime = (new Date).getTime(); 24 | this.timer = setInterval (this.step.bind(this), 13); 25 | }, 26 | 27 | step: function() { 28 | var time = (new Date).getTime(); 29 | var Tpos = (time - this.startTime) / (this.duration); 30 | if (time >= this.duration+this.startTime) { 31 | this.now = this.to; 32 | clearInterval (this.timer); 33 | this.timer = null; 34 | if (this.options.onComplete) setTimeout(this.options.onComplete.bind(this), 10); 35 | } 36 | else { 37 | this.now = ((-Math.cos(Tpos*Math.PI)/2) + 0.5) * (this.to-this.from) + this.from; 38 | //this time-position, sinoidal transition thing is from script.aculo.us 39 | } 40 | this.increase(); 41 | }, 42 | 43 | custom: function(from, to) { 44 | if (this.timer != null) return; 45 | this.from = from; 46 | this.to = to; 47 | this.go(); 48 | }, 49 | 50 | hide: function() { 51 | this.now = 0; 52 | this.increase(); 53 | }, 54 | 55 | clearTimer: function() { 56 | clearInterval(this.timer); 57 | this.timer = null; 58 | } 59 | } 60 | 61 | //stretchers 62 | fx.Layout = Class.create(); 63 | fx.Layout.prototype = Object.extend(new fx.Base(), { 64 | initialize: function(el, options) { 65 | this.el = $(el); 66 | this.el.style.overflow = "hidden"; 67 | this.el.iniWidth = this.el.offsetWidth; 68 | this.el.iniHeight = this.el.offsetHeight; 69 | this.setOptions(options); 70 | } 71 | }); 72 | 73 | fx.Height = Class.create(); 74 | Object.extend(Object.extend(fx.Height.prototype, fx.Layout.prototype), { 75 | increase: function() { 76 | this.el.style.height = this.now + "px"; 77 | }, 78 | 79 | toggle: function() { 80 | if (this.el.offsetHeight > 0) this.custom(this.el.offsetHeight, 0); 81 | else this.custom(0, this.el.scrollHeight); 82 | } 83 | }); 84 | -------------------------------------------------------------------------------- /system/language/english/db_lang.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsuported_feature'); 83 | } 84 | 85 | } 86 | 87 | /* End of file mssql_utility.php */ 88 | /* Location: ./system/database/drivers/mssql/mssql_utility.php */ -------------------------------------------------------------------------------- /system/database/drivers/mysqli/mysqli_utility.php: -------------------------------------------------------------------------------- 1 | db->_escape_identifiers($table); 52 | } 53 | 54 | // -------------------------------------------------------------------- 55 | 56 | /** 57 | * Repair table query 58 | * 59 | * Generates a platform-specific query so that a table can be repaired 60 | * 61 | * @access private 62 | * @param string the table name 63 | * @return object 64 | */ 65 | function _repair_table($table) 66 | { 67 | return "REPAIR TABLE ".$this->db->_escape_identifiers($table); 68 | } 69 | 70 | // -------------------------------------------------------------------- 71 | 72 | /** 73 | * MySQLi Export 74 | * 75 | * @access private 76 | * @param array Preferences 77 | * @return mixed 78 | */ 79 | function _backup($params = array()) 80 | { 81 | // Currently unsupported 82 | return $this->db->display_error('db_unsuported_feature'); 83 | } 84 | } 85 | 86 | /* End of file mysqli_utility.php */ 87 | /* Location: ./system/database/drivers/mysqli/mysqli_utility.php */ -------------------------------------------------------------------------------- /system/database/drivers/sqlsrv/sqlsrv_utility.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsuported_feature'); 83 | } 84 | 85 | } 86 | 87 | /* End of file mssql_utility.php */ 88 | /* Location: ./system/database/drivers/mssql/mssql_utility.php */ -------------------------------------------------------------------------------- /system/helpers/directory_helper.php: -------------------------------------------------------------------------------- 1 | 0) && @is_dir($source_dir.$file)) 61 | { 62 | $filedata[$file] = directory_map($source_dir.$file.DIRECTORY_SEPARATOR, $new_depth, $hidden); 63 | } 64 | else 65 | { 66 | $filedata[] = $file; 67 | } 68 | } 69 | 70 | closedir($fp); 71 | return $filedata; 72 | } 73 | 74 | return FALSE; 75 | } 76 | } 77 | 78 | 79 | /* End of file directory_helper.php */ 80 | /* Location: ./system/helpers/directory_helper.php */ -------------------------------------------------------------------------------- /system/database/drivers/sqlite/sqlite_utility.php: -------------------------------------------------------------------------------- 1 | db_debug) 41 | { 42 | return $this->db->display_error('db_unsuported_feature'); 43 | } 44 | return array(); 45 | } 46 | 47 | // -------------------------------------------------------------------- 48 | 49 | /** 50 | * Optimize table query 51 | * 52 | * Is optimization even supported in SQLite? 53 | * 54 | * @access private 55 | * @param string the table name 56 | * @return object 57 | */ 58 | function _optimize_table($table) 59 | { 60 | return FALSE; 61 | } 62 | 63 | // -------------------------------------------------------------------- 64 | 65 | /** 66 | * Repair table query 67 | * 68 | * Are table repairs even supported in SQLite? 69 | * 70 | * @access private 71 | * @param string the table name 72 | * @return object 73 | */ 74 | function _repair_table($table) 75 | { 76 | return FALSE; 77 | } 78 | 79 | // -------------------------------------------------------------------- 80 | 81 | /** 82 | * SQLite Export 83 | * 84 | * @access private 85 | * @param array Preferences 86 | * @return mixed 87 | */ 88 | function _backup($params = array()) 89 | { 90 | // Currently unsupported 91 | return $this->db->display_error('db_unsuported_feature'); 92 | } 93 | } 94 | 95 | /* End of file sqlite_utility.php */ 96 | /* Location: ./system/database/drivers/sqlite/sqlite_utility.php */ -------------------------------------------------------------------------------- /system/helpers/typography_helper.php: -------------------------------------------------------------------------------- 1 | load->library('typography'); 44 | 45 | return $CI->typography->nl2br_except_pre($str); 46 | } 47 | } 48 | 49 | // ------------------------------------------------------------------------ 50 | 51 | /** 52 | * Auto Typography Wrapper Function 53 | * 54 | * 55 | * @access public 56 | * @param string 57 | * @param bool whether to allow javascript event handlers 58 | * @param bool whether to reduce multiple instances of double newlines to two 59 | * @return string 60 | */ 61 | if ( ! function_exists('auto_typography')) 62 | { 63 | function auto_typography($str, $strip_js_event_handlers = TRUE, $reduce_linebreaks = FALSE) 64 | { 65 | $CI =& get_instance(); 66 | $CI->load->library('typography'); 67 | return $CI->typography->auto_typography($str, $strip_js_event_handlers, $reduce_linebreaks); 68 | } 69 | } 70 | 71 | 72 | // -------------------------------------------------------------------- 73 | 74 | /** 75 | * HTML Entities Decode 76 | * 77 | * This function is a replacement for html_entity_decode() 78 | * 79 | * @access public 80 | * @param string 81 | * @return string 82 | */ 83 | if ( ! function_exists('entity_decode')) 84 | { 85 | function entity_decode($str, $charset='UTF-8') 86 | { 87 | global $SEC; 88 | return $SEC->entity_decode($str, $charset); 89 | } 90 | } 91 | 92 | /* End of file typography_helper.php */ 93 | /* Location: ./system/helpers/typography_helper.php */ -------------------------------------------------------------------------------- /license.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2008 - 2011, EllisLab, Inc. 2 | All rights reserved. 3 | 4 | This license is a legal agreement between you and EllisLab Inc. for the use 5 | of CodeIgniter Software (the "Software"). By obtaining the Software you 6 | agree to comply with the terms and conditions of this license. 7 | 8 | PERMITTED USE 9 | You are permitted to use, copy, modify, and distribute the Software and its 10 | documentation, with or without modification, for any purpose, provided that 11 | the following conditions are met: 12 | 13 | 1. A copy of this license agreement must be included with the distribution. 14 | 15 | 2. Redistributions of source code must retain the above copyright notice in 16 | all source code files. 17 | 18 | 3. Redistributions in binary form must reproduce the above copyright notice 19 | in the documentation and/or other materials provided with the distribution. 20 | 21 | 4. Any files that have been modified must carry notices stating the nature 22 | of the change and the names of those who changed them. 23 | 24 | 5. Products derived from the Software must include an acknowledgment that 25 | they are derived from CodeIgniter in their documentation and/or other 26 | materials provided with the distribution. 27 | 28 | 6. Products derived from the Software may not be called "CodeIgniter", 29 | nor may "CodeIgniter" appear in their name, without prior written 30 | permission from EllisLab, Inc. 31 | 32 | INDEMNITY 33 | You agree to indemnify and hold harmless the authors of the Software and 34 | any contributors for any direct, indirect, incidental, or consequential 35 | third-party claims, actions or suits, as well as any related expenses, 36 | liabilities, damages, settlements or fees arising from your use or misuse 37 | of the Software, or a violation of any terms of this license. 38 | 39 | DISCLAIMER OF WARRANTY 40 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESSED OR 41 | IMPLIED, INCLUDING, BUT NOT LIMITED TO, WARRANTIES OF QUALITY, PERFORMANCE, 42 | NON-INFRINGEMENT, MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE. 43 | 44 | LIMITATIONS OF LIABILITY 45 | YOU ASSUME ALL RISK ASSOCIATED WITH THE INSTALLATION AND USE OF THE SOFTWARE. 46 | IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS OF THE SOFTWARE BE LIABLE 47 | FOR CLAIMS, DAMAGES OR OTHER LIABILITY ARISING FROM, OUT OF, OR IN CONNECTION 48 | WITH THE SOFTWARE. LICENSE HOLDERS ARE SOLELY RESPONSIBLE FOR DETERMINING THE 49 | APPROPRIATENESS OF USE AND ASSUME ALL RISKS ASSOCIATED WITH ITS USE, INCLUDING 50 | BUT NOT LIMITED TO THE RISKS OF PROGRAM ERRORS, DAMAGE TO EQUIPMENT, LOSS OF 51 | DATA OR SOFTWARE PROGRAMS, OR UNAVAILABILITY OR INTERRUPTION OF OPERATIONS. 52 | -------------------------------------------------------------------------------- /system/database/drivers/pdo/pdo_utility.php: -------------------------------------------------------------------------------- 1 | db->db_debug) 37 | { 38 | return $this->db->display_error('db_unsuported_feature'); 39 | } 40 | return FALSE; 41 | } 42 | 43 | // -------------------------------------------------------------------- 44 | 45 | /** 46 | * Optimize table query 47 | * 48 | * Generates a platform-specific query so that a table can be optimized 49 | * 50 | * @access private 51 | * @param string the table name 52 | * @return object 53 | */ 54 | function _optimize_table($table) 55 | { 56 | // Not a supported PDO feature 57 | if ($this->db->db_debug) 58 | { 59 | return $this->db->display_error('db_unsuported_feature'); 60 | } 61 | return FALSE; 62 | } 63 | 64 | // -------------------------------------------------------------------- 65 | 66 | /** 67 | * Repair table query 68 | * 69 | * Generates a platform-specific query so that a table can be repaired 70 | * 71 | * @access private 72 | * @param string the table name 73 | * @return object 74 | */ 75 | function _repair_table($table) 76 | { 77 | // Not a supported PDO feature 78 | if ($this->db->db_debug) 79 | { 80 | return $this->db->display_error('db_unsuported_feature'); 81 | } 82 | return FALSE; 83 | } 84 | 85 | // -------------------------------------------------------------------- 86 | 87 | /** 88 | * PDO Export 89 | * 90 | * @access private 91 | * @param array Preferences 92 | * @return mixed 93 | */ 94 | function _backup($params = array()) 95 | { 96 | // Currently unsupported 97 | return $this->db->display_error('db_unsuported_feature'); 98 | } 99 | 100 | } 101 | 102 | /* End of file pdo_utility.php */ 103 | /* Location: ./system/database/drivers/pdo/pdo_utility.php */ -------------------------------------------------------------------------------- /system/database/drivers/odbc/odbc_utility.php: -------------------------------------------------------------------------------- 1 | db->db_debug) 37 | { 38 | return $this->db->display_error('db_unsuported_feature'); 39 | } 40 | return FALSE; 41 | } 42 | 43 | // -------------------------------------------------------------------- 44 | 45 | /** 46 | * Optimize table query 47 | * 48 | * Generates a platform-specific query so that a table can be optimized 49 | * 50 | * @access private 51 | * @param string the table name 52 | * @return object 53 | */ 54 | function _optimize_table($table) 55 | { 56 | // Not a supported ODBC feature 57 | if ($this->db->db_debug) 58 | { 59 | return $this->db->display_error('db_unsuported_feature'); 60 | } 61 | return FALSE; 62 | } 63 | 64 | // -------------------------------------------------------------------- 65 | 66 | /** 67 | * Repair table query 68 | * 69 | * Generates a platform-specific query so that a table can be repaired 70 | * 71 | * @access private 72 | * @param string the table name 73 | * @return object 74 | */ 75 | function _repair_table($table) 76 | { 77 | // Not a supported ODBC feature 78 | if ($this->db->db_debug) 79 | { 80 | return $this->db->display_error('db_unsuported_feature'); 81 | } 82 | return FALSE; 83 | } 84 | 85 | // -------------------------------------------------------------------- 86 | 87 | /** 88 | * ODBC Export 89 | * 90 | * @access private 91 | * @param array Preferences 92 | * @return mixed 93 | */ 94 | function _backup($params = array()) 95 | { 96 | // Currently unsupported 97 | return $this->db->display_error('db_unsuported_feature'); 98 | } 99 | 100 | } 101 | 102 | /* End of file odbc_utility.php */ 103 | /* Location: ./system/database/drivers/odbc/odbc_utility.php */ -------------------------------------------------------------------------------- /system/helpers/cookie_helper.php: -------------------------------------------------------------------------------- 1 | input->set_cookie($name, $value, $expire, $domain, $path, $prefix, $secure); 52 | } 53 | } 54 | 55 | // -------------------------------------------------------------------- 56 | 57 | /** 58 | * Fetch an item from the COOKIE array 59 | * 60 | * @access public 61 | * @param string 62 | * @param bool 63 | * @return mixed 64 | */ 65 | if ( ! function_exists('get_cookie')) 66 | { 67 | function get_cookie($index = '', $xss_clean = FALSE) 68 | { 69 | $CI =& get_instance(); 70 | 71 | $prefix = ''; 72 | 73 | if ( ! isset($_COOKIE[$index]) && config_item('cookie_prefix') != '') 74 | { 75 | $prefix = config_item('cookie_prefix'); 76 | } 77 | 78 | return $CI->input->cookie($prefix.$index, $xss_clean); 79 | } 80 | } 81 | 82 | // -------------------------------------------------------------------- 83 | 84 | /** 85 | * Delete a COOKIE 86 | * 87 | * @param mixed 88 | * @param string the cookie domain. Usually: .yourdomain.com 89 | * @param string the cookie path 90 | * @param string the cookie prefix 91 | * @return void 92 | */ 93 | if ( ! function_exists('delete_cookie')) 94 | { 95 | function delete_cookie($name = '', $domain = '', $path = '/', $prefix = '') 96 | { 97 | set_cookie($name, '', '', $domain, $path, $prefix); 98 | } 99 | } 100 | 101 | 102 | /* End of file cookie_helper.php */ 103 | /* Location: ./system/helpers/cookie_helper.php */ -------------------------------------------------------------------------------- /system/helpers/array_helper.php: -------------------------------------------------------------------------------- 1 | load->model('m_user'); 14 | $this->load->library('form_validation'); 15 | } 16 | 17 | // route /login 18 | public function index() 19 | { 20 | if ($this->m_user->is_logged_in()) { redirect('admin'); } 21 | 22 | $this->form_validation->set_rules('username', 'Username', 'required'); 23 | $this->form_validation->set_rules('password', 'Password', 'required'); 24 | 25 | if ($this->form_validation->run()) { 26 | $username = $this->input->post('username'); 27 | $password = $this->input->post('password'); 28 | 29 | if ($user = $this->m_user->get_by_username($username)) { 30 | if ($this->m_user->check_password( $password, $user['password'] )) { 31 | $this->m_user->allow_pass( $user ); 32 | redirect('admin'); 33 | } else { $this->data['login_error'] = 'Invalid username or password'; } 34 | } else { $this->data['login_error'] = 'Username not found'; } 35 | } 36 | $this->load->view('login/v_login', $this->data); 37 | } 38 | 39 | // route /register -- check settings in /application/config/routes.php 40 | public function register() { 41 | if ($this->m_user->is_logged_in()) { redirect('admin'); } 42 | 43 | $this->form_validation->set_rules('fullname', 'Full Name', 'required'); 44 | $this->form_validation->set_rules('username', 'Username', 'required|is_unique[users.username]'); 45 | $this->form_validation->set_rules('email', 'Email', 'required|valid_email|is_unique[users.email]'); 46 | $this->form_validation->set_rules('password', 'Password', 'required'); 47 | $this->form_validation->set_rules('cpassword', 'Password', 'required|matches[password]'); 48 | 49 | if ($this->form_validation->run()) { 50 | $user = array( 51 | 'username' => $this->input->post('username'), 52 | 'email' => $this->input->post('email'), 53 | 'fullname' => $this->input->post('fullname'), 54 | 'password' => $this->m_user->hash_password( $this->input->post('password') ) 55 | ); 56 | if ( $this->m_user->save($user) ) { 57 | $this->data['register_success'] = 'Registration successful. Click here to login.'; 58 | } else { $this->data['register_error'] = 'Saving data failed. Contact administrator.'; } 59 | } 60 | $this->load->view('login/v_register', $this->data); 61 | } 62 | 63 | // route /logout -- check settings in /application/config/routes.php 64 | public function logout() { 65 | $this->m_user->remove_pass(); 66 | $this->data['login_success'] = 'You have been logged out. Thank you.'; 67 | $this->load->view('login/v_login', $this->data); 68 | } 69 | 70 | // noaccess to show no access message 71 | public function noaccess() { 72 | $this->data['login_error'] = 'You do not have access or your login has expired.'; 73 | $this->load->view('login/v_login', $this->data); 74 | } 75 | } 76 | 77 | /* End of file login.php */ 78 | /* Location: ./application/controllers/login.php */ -------------------------------------------------------------------------------- /system/libraries/Log.php: -------------------------------------------------------------------------------- 1 | '1', 'DEBUG' => '2', 'INFO' => '3', 'ALL' => '4'); 34 | 35 | /** 36 | * Constructor 37 | */ 38 | public function __construct() 39 | { 40 | $config =& get_config(); 41 | 42 | $this->_log_path = ($config['log_path'] != '') ? $config['log_path'] : APPPATH.'logs/'; 43 | 44 | if ( ! is_dir($this->_log_path) OR ! is_really_writable($this->_log_path)) 45 | { 46 | $this->_enabled = FALSE; 47 | } 48 | 49 | if (is_numeric($config['log_threshold'])) 50 | { 51 | $this->_threshold = $config['log_threshold']; 52 | } 53 | 54 | if ($config['log_date_format'] != '') 55 | { 56 | $this->_date_fmt = $config['log_date_format']; 57 | } 58 | } 59 | 60 | // -------------------------------------------------------------------- 61 | 62 | /** 63 | * Write Log File 64 | * 65 | * Generally this function will be called using the global log_message() function 66 | * 67 | * @param string the error level 68 | * @param string the error message 69 | * @param bool whether the error is a native PHP error 70 | * @return bool 71 | */ 72 | public function write_log($level = 'error', $msg, $php_error = FALSE) 73 | { 74 | if ($this->_enabled === FALSE) 75 | { 76 | return FALSE; 77 | } 78 | 79 | $level = strtoupper($level); 80 | 81 | if ( ! isset($this->_levels[$level]) OR ($this->_levels[$level] > $this->_threshold)) 82 | { 83 | return FALSE; 84 | } 85 | 86 | $filepath = $this->_log_path.'log-'.date('Y-m-d').'.php'; 87 | $message = ''; 88 | 89 | if ( ! file_exists($filepath)) 90 | { 91 | $message .= "<"."?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); ?".">\n\n"; 92 | } 93 | 94 | if ( ! $fp = @fopen($filepath, FOPEN_WRITE_CREATE)) 95 | { 96 | return FALSE; 97 | } 98 | 99 | $message .= $level.' '.(($level == 'INFO') ? ' -' : '-').' '.date($this->_date_fmt). ' --> '.$msg."\n"; 100 | 101 | flock($fp, LOCK_EX); 102 | fwrite($fp, $message); 103 | flock($fp, LOCK_UN); 104 | fclose($fp); 105 | 106 | @chmod($filepath, FILE_WRITE_MODE); 107 | return TRUE; 108 | } 109 | 110 | } 111 | // END Log Class 112 | 113 | /* End of file Log.php */ 114 | /* Location: ./system/libraries/Log.php */ -------------------------------------------------------------------------------- /system/helpers/download_helper.php: -------------------------------------------------------------------------------- 1 | security->xss_clean($str, $is_image); 44 | } 45 | } 46 | 47 | // ------------------------------------------------------------------------ 48 | 49 | /** 50 | * Sanitize Filename 51 | * 52 | * @access public 53 | * @param string 54 | * @return string 55 | */ 56 | if ( ! function_exists('sanitize_filename')) 57 | { 58 | function sanitize_filename($filename) 59 | { 60 | $CI =& get_instance(); 61 | return $CI->security->sanitize_filename($filename); 62 | } 63 | } 64 | 65 | // -------------------------------------------------------------------- 66 | 67 | /** 68 | * Hash encode a string 69 | * 70 | * @access public 71 | * @param string 72 | * @return string 73 | */ 74 | if ( ! function_exists('do_hash')) 75 | { 76 | function do_hash($str, $type = 'sha1') 77 | { 78 | if ($type == 'sha1') 79 | { 80 | return sha1($str); 81 | } 82 | else 83 | { 84 | return md5($str); 85 | } 86 | } 87 | } 88 | 89 | // ------------------------------------------------------------------------ 90 | 91 | /** 92 | * Strip Image Tags 93 | * 94 | * @access public 95 | * @param string 96 | * @return string 97 | */ 98 | if ( ! function_exists('strip_image_tags')) 99 | { 100 | function strip_image_tags($str) 101 | { 102 | $str = preg_replace("##", "\\1", $str); 103 | $str = preg_replace("##", "\\1", $str); 104 | 105 | return $str; 106 | } 107 | } 108 | 109 | // ------------------------------------------------------------------------ 110 | 111 | /** 112 | * Convert PHP tags to entities 113 | * 114 | * @access public 115 | * @param string 116 | * @return string 117 | */ 118 | if ( ! function_exists('encode_php_tags')) 119 | { 120 | function encode_php_tags($str) 121 | { 122 | return str_replace(array(''), array('<?php', '<?PHP', '<?', '?>'), $str); 123 | } 124 | } 125 | 126 | 127 | /* End of file security_helper.php */ 128 | /* Location: ./system/helpers/security_helper.php */ -------------------------------------------------------------------------------- /system/libraries/Cache/drivers/Cache_dummy.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Quick Reference Chart : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Quick Reference Chart

59 | 60 |

For a PDF version of this chart, click here.

61 | 62 |

63 | 64 |
65 | 66 | 67 | 68 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /system/language/english/date_lang.php: -------------------------------------------------------------------------------- 1 | conn_id) 41 | { 42 | return "SELECT '" . $this->database . "'"; 43 | } 44 | else 45 | { 46 | return FALSE; 47 | } 48 | } 49 | 50 | // -------------------------------------------------------------------- 51 | 52 | /** 53 | * Optimize table query 54 | * 55 | * Generates a platform-specific query so that a table can be optimized 56 | * 57 | * @access private 58 | * @param string the table name 59 | * @return object 60 | * @link http://www.cubrid.org/manual/840/en/Optimize%20Database 61 | */ 62 | function _optimize_table($table) 63 | { 64 | // No SQL based support in CUBRID as of version 8.4.0. Database or 65 | // table optimization can be performed using CUBRID Manager 66 | // database administration tool. See the link above for more info. 67 | return FALSE; 68 | } 69 | 70 | // -------------------------------------------------------------------- 71 | 72 | /** 73 | * Repair table query 74 | * 75 | * Generates a platform-specific query so that a table can be repaired 76 | * 77 | * @access private 78 | * @param string the table name 79 | * @return object 80 | * @link http://www.cubrid.org/manual/840/en/Checking%20Database%20Consistency 81 | */ 82 | function _repair_table($table) 83 | { 84 | // Not supported in CUBRID as of version 8.4.0. Database or 85 | // table consistency can be checked using CUBRID Manager 86 | // database administration tool. See the link above for more info. 87 | return FALSE; 88 | } 89 | 90 | // -------------------------------------------------------------------- 91 | /** 92 | * CUBRID Export 93 | * 94 | * @access private 95 | * @param array Preferences 96 | * @return mixed 97 | */ 98 | function _backup($params = array()) 99 | { 100 | // No SQL based support in CUBRID as of version 8.4.0. Database or 101 | // table backup can be performed using CUBRID Manager 102 | // database administration tool. 103 | return $this->db->display_error('db_unsuported_feature'); 104 | } 105 | } 106 | 107 | /* End of file cubrid_utility.php */ 108 | /* Location: ./system/database/drivers/cubrid/cubrid_utility.php */ -------------------------------------------------------------------------------- /application/config/database.php: -------------------------------------------------------------------------------- 1 | 3 | * 4 | * Prototype is freely distributable under the terms of an MIT-style license. 5 | * 6 | * For details, see the Prototype web site: http://prototype.conio.net/ 7 | * 8 | /*--------------------------------------------------------------------------*/ 9 | 10 | 11 | //note: this is a stripped down version of prototype, to be used with moo.fx by mad4milk (http://moofx.mad4milk.net). 12 | 13 | var Class = { 14 | create: function() { 15 | return function() { 16 | this.initialize.apply(this, arguments); 17 | } 18 | } 19 | } 20 | 21 | Object.extend = function(destination, source) { 22 | for (property in source) { 23 | destination[property] = source[property]; 24 | } 25 | return destination; 26 | } 27 | 28 | Function.prototype.bind = function(object) { 29 | var __method = this; 30 | return function() { 31 | return __method.apply(object, arguments); 32 | } 33 | } 34 | 35 | function $() { 36 | var elements = new Array(); 37 | 38 | for (var i = 0; i < arguments.length; i++) { 39 | var element = arguments[i]; 40 | if (typeof element == 'string') 41 | element = document.getElementById(element); 42 | 43 | if (arguments.length == 1) 44 | return element; 45 | 46 | elements.push(element); 47 | } 48 | 49 | return elements; 50 | } 51 | 52 | //------------------------- 53 | 54 | document.getElementsByClassName = function(className) { 55 | var children = document.getElementsByTagName('*') || document.all; 56 | var elements = new Array(); 57 | 58 | for (var i = 0; i < children.length; i++) { 59 | var child = children[i]; 60 | var classNames = child.className.split(' '); 61 | for (var j = 0; j < classNames.length; j++) { 62 | if (classNames[j] == className) { 63 | elements.push(child); 64 | break; 65 | } 66 | } 67 | } 68 | 69 | return elements; 70 | } 71 | 72 | //------------------------- 73 | 74 | if (!window.Element) { 75 | var Element = new Object(); 76 | } 77 | 78 | Object.extend(Element, { 79 | remove: function(element) { 80 | element = $(element); 81 | element.parentNode.removeChild(element); 82 | }, 83 | 84 | hasClassName: function(element, className) { 85 | element = $(element); 86 | if (!element) 87 | return; 88 | var a = element.className.split(' '); 89 | for (var i = 0; i < a.length; i++) { 90 | if (a[i] == className) 91 | return true; 92 | } 93 | return false; 94 | }, 95 | 96 | addClassName: function(element, className) { 97 | element = $(element); 98 | Element.removeClassName(element, className); 99 | element.className += ' ' + className; 100 | }, 101 | 102 | removeClassName: function(element, className) { 103 | element = $(element); 104 | if (!element) 105 | return; 106 | var newClassName = ''; 107 | var a = element.className.split(' '); 108 | for (var i = 0; i < a.length; i++) { 109 | if (a[i] != className) { 110 | if (i > 0) 111 | newClassName += ' '; 112 | newClassName += a[i]; 113 | } 114 | } 115 | element.className = newClassName; 116 | }, 117 | 118 | // removes whitespace-only text node children 119 | cleanWhitespace: function(element) { 120 | element = $(element); 121 | for (var i = 0; i < element.childNodes.length; i++) { 122 | var node = element.childNodes[i]; 123 | if (node.nodeType == 3 && !/\S/.test(node.nodeValue)) 124 | Element.remove(node); 125 | } 126 | } 127 | }); -------------------------------------------------------------------------------- /application/config/smileys.php: -------------------------------------------------------------------------------- 1 | array('grin.gif', '19', '19', 'grin'), 20 | ':lol:' => array('lol.gif', '19', '19', 'LOL'), 21 | ':cheese:' => array('cheese.gif', '19', '19', 'cheese'), 22 | ':)' => array('smile.gif', '19', '19', 'smile'), 23 | ';-)' => array('wink.gif', '19', '19', 'wink'), 24 | ';)' => array('wink.gif', '19', '19', 'wink'), 25 | ':smirk:' => array('smirk.gif', '19', '19', 'smirk'), 26 | ':roll:' => array('rolleyes.gif', '19', '19', 'rolleyes'), 27 | ':-S' => array('confused.gif', '19', '19', 'confused'), 28 | ':wow:' => array('surprise.gif', '19', '19', 'surprised'), 29 | ':bug:' => array('bigsurprise.gif', '19', '19', 'big surprise'), 30 | ':-P' => array('tongue_laugh.gif', '19', '19', 'tongue laugh'), 31 | '%-P' => array('tongue_rolleye.gif', '19', '19', 'tongue rolleye'), 32 | ';-P' => array('tongue_wink.gif', '19', '19', 'tongue wink'), 33 | ':P' => array('raspberry.gif', '19', '19', 'raspberry'), 34 | ':blank:' => array('blank.gif', '19', '19', 'blank stare'), 35 | ':long:' => array('longface.gif', '19', '19', 'long face'), 36 | ':ohh:' => array('ohh.gif', '19', '19', 'ohh'), 37 | ':grrr:' => array('grrr.gif', '19', '19', 'grrr'), 38 | ':gulp:' => array('gulp.gif', '19', '19', 'gulp'), 39 | '8-/' => array('ohoh.gif', '19', '19', 'oh oh'), 40 | ':down:' => array('downer.gif', '19', '19', 'downer'), 41 | ':red:' => array('embarrassed.gif', '19', '19', 'red face'), 42 | ':sick:' => array('sick.gif', '19', '19', 'sick'), 43 | ':shut:' => array('shuteye.gif', '19', '19', 'shut eye'), 44 | ':-/' => array('hmm.gif', '19', '19', 'hmmm'), 45 | '>:(' => array('mad.gif', '19', '19', 'mad'), 46 | ':mad:' => array('mad.gif', '19', '19', 'mad'), 47 | '>:-(' => array('angry.gif', '19', '19', 'angry'), 48 | ':angry:' => array('angry.gif', '19', '19', 'angry'), 49 | ':zip:' => array('zip.gif', '19', '19', 'zipper'), 50 | ':kiss:' => array('kiss.gif', '19', '19', 'kiss'), 51 | ':ahhh:' => array('shock.gif', '19', '19', 'shock'), 52 | ':coolsmile:' => array('shade_smile.gif', '19', '19', 'cool smile'), 53 | ':coolsmirk:' => array('shade_smirk.gif', '19', '19', 'cool smirk'), 54 | ':coolgrin:' => array('shade_grin.gif', '19', '19', 'cool grin'), 55 | ':coolhmm:' => array('shade_hmm.gif', '19', '19', 'cool hmm'), 56 | ':coolmad:' => array('shade_mad.gif', '19', '19', 'cool mad'), 57 | ':coolcheese:' => array('shade_cheese.gif', '19', '19', 'cool cheese'), 58 | ':vampire:' => array('vampire.gif', '19', '19', 'vampire'), 59 | ':snake:' => array('snake.gif', '19', '19', 'snake'), 60 | ':exclaim:' => array('exclaim.gif', '19', '19', 'excaim'), 61 | ':question:' => array('question.gif', '19', '19', 'question') // no comma after last item 62 | 63 | ); 64 | 65 | /* End of file smileys.php */ 66 | /* Location: ./application/config/smileys.php */ -------------------------------------------------------------------------------- /user_guide/general/requirements.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Server Requirements : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Server Requirements

59 | 60 |
    61 |
  • PHP version 5.1.6 or newer.
  • 62 |
  • A Database is required for most web application programming. Current supported databases are MySQL (4.1+), MySQLi, MS SQL, Postgres, Oracle, SQLite, and ODBC.
  • 63 |
64 | 65 | 66 | 67 |
68 | 69 | 70 | 71 | 72 | 80 | 81 | 82 | -------------------------------------------------------------------------------- /system/core/Benchmark.php: -------------------------------------------------------------------------------- 1 | marker[$name] = microtime(); 54 | } 55 | 56 | // -------------------------------------------------------------------- 57 | 58 | /** 59 | * Calculates the time difference between two marked points. 60 | * 61 | * If the first parameter is empty this function instead returns the 62 | * {elapsed_time} pseudo-variable. This permits the full system 63 | * execution time to be shown in a template. The output class will 64 | * swap the real value for this variable. 65 | * 66 | * @access public 67 | * @param string a particular marked point 68 | * @param string a particular marked point 69 | * @param integer the number of decimal places 70 | * @return mixed 71 | */ 72 | function elapsed_time($point1 = '', $point2 = '', $decimals = 4) 73 | { 74 | if ($point1 == '') 75 | { 76 | return '{elapsed_time}'; 77 | } 78 | 79 | if ( ! isset($this->marker[$point1])) 80 | { 81 | return ''; 82 | } 83 | 84 | if ( ! isset($this->marker[$point2])) 85 | { 86 | $this->marker[$point2] = microtime(); 87 | } 88 | 89 | list($sm, $ss) = explode(' ', $this->marker[$point1]); 90 | list($em, $es) = explode(' ', $this->marker[$point2]); 91 | 92 | return number_format(($em + $es) - ($sm + $ss), $decimals); 93 | } 94 | 95 | // -------------------------------------------------------------------- 96 | 97 | /** 98 | * Memory Usage 99 | * 100 | * This function returns the {memory_usage} pseudo-variable. 101 | * This permits it to be put it anywhere in a template 102 | * without the memory being calculated until the end. 103 | * The output class will swap the real value for this variable. 104 | * 105 | * @access public 106 | * @return string 107 | */ 108 | function memory_usage() 109 | { 110 | return '{memory_usage}'; 111 | } 112 | 113 | } 114 | 115 | // END CI_Benchmark class 116 | 117 | /* End of file Benchmark.php */ 118 | /* Location: ./system/core/Benchmark.php */ -------------------------------------------------------------------------------- /user_guide/overview/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | CodeIgniter Overview : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

CodeIgniter Overview

59 | 60 |

The following pages describe the broad concepts behind CodeIgniter:

61 | 62 | 70 | 71 | 72 | 73 | 74 |
75 | 76 | 77 | 78 | 82 | 83 | 84 | -------------------------------------------------------------------------------- /application/config/autoload.php: -------------------------------------------------------------------------------- 1 | 8 | load->view('template/v_admin_header.php'); ?> 9 |
10 |
11 |
12 | Register 13 |
 
14 | 15 | $register_error
" : ''; ?> 16 | $register_success
" : ''; ?> 17 | 18 | 19 | 20 |
21 | 22 |
23 | 24 | ', '

'); ?> 25 |
26 |
27 |
28 | 29 |
30 | 31 | ', '

'); ?> 32 |
33 |
34 |
35 | 36 |
37 | 38 | ', '

'); ?> 39 |
40 |
41 |
42 | 43 |
44 | 45 | ', '

'); ?> 46 |
47 |
48 |
49 | 50 |
51 | 52 | ', '

'); ?> 53 |
54 |
55 |
56 | 57 |
58 | 59 |
60 |
61 | 62 | 63 | 64 | 65 | 66 |

Login

67 | 68 | 69 | 70 | load->view('template/v_admin_footer.php'); ?> 71 | -------------------------------------------------------------------------------- /application/models/m_user.php: -------------------------------------------------------------------------------- 1 | db->insert($this->table , $user_data); 17 | return $this->db->insert_id(); 18 | } 19 | 20 | // Update an existing user 21 | function update( $user_data ) { 22 | if (isset($user_data['id'])) { 23 | $this->db->where('id', $user_data['id'] ); 24 | $this->db->update( $this->table , $user_data); 25 | return $this->db->affected_rows(); 26 | } 27 | return false; 28 | } 29 | 30 | // get user by username 31 | function get_by_username( $username ) { 32 | $query = $this->db->get_where($this->table, array('username' => $username), 1); 33 | if( $query->num_rows() > 0 ) return $query->row_array(); 34 | return false; 35 | } 36 | 37 | // set login session 38 | function allow_pass( $user_data ) { 39 | $this->session->set_userdata( array( 'last_activity' => time(), 'logged_in' => 'yes', 'user' => $user_data ) ); 40 | } 41 | 42 | // Check if user is logged in and update session 43 | function is_logged_in() { 44 | $last_activity = $this->session->userdata('last_activity'); 45 | $logged_in = $this->session->userdata('logged_in'); 46 | $user = $this->session->userdata('user'); 47 | 48 | if ( ($logged_in == 'yes') 49 | && ((time() - $last_activity) < $this->max_idle_time )) { 50 | $this->allow_pass( $user ); 51 | return true; 52 | } else { 53 | $this->remove_pass(); 54 | return false; 55 | } 56 | } 57 | 58 | // remove pass 59 | function remove_pass() { 60 | $array_items = array('last_activity' => '', 'logged_in' => '', 'user' => ''); 61 | $this->session->unset_userdata($array_items); 62 | } 63 | 64 | // get user by id 65 | function get_by_id( $id ) { 66 | $query = $this->db->get_where($this->table, array('id' => $id), 1); 67 | if( $query->num_rows() > 0 ) return $query->row_array(); 68 | return false; 69 | } 70 | 71 | // Check if email address already exists 72 | function email_exists( $email ) { 73 | $query = $this->db->get_where($this->table, array('email' => $email), 1); 74 | if( $query->num_rows() > 0 ) return true; 75 | return false; 76 | } 77 | 78 | // Check if username already exists 79 | function username_exists( $username ) { 80 | $query = $this->db->get_where($this->table, array('username' => $username), 1); 81 | if( $query->num_rows() > 0 ) return true; 82 | return false; 83 | } 84 | 85 | // Generate hashed password 86 | function hash_password( $password ) { 87 | $salt = $this->generate_salt(); 88 | return $salt.'.'.md5( $salt.$password); 89 | } 90 | 91 | // Check if password is valid 92 | function check_password( $password, $hashed_password ) { 93 | list($salt, $hash) = explode('.', $hashed_password); 94 | $hashed2 = $salt.'.'.md5( $salt.$password); 95 | return ($hashed_password == $hashed2); 96 | } 97 | 98 | // create salt for password hashing 99 | private function generate_salt( $length = 10 ) { 100 | $characterList = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; 101 | $i = 0; 102 | $salt = ""; 103 | while ($i < $length) { 104 | $salt .= $characterList{mt_rand(0, (strlen($characterList) - 1))}; 105 | $i++; 106 | } 107 | return $salt; 108 | } 109 | 110 | } 111 | 112 | /* End of file m_user.php */ 113 | /* Location: ./application/models/m_user.php */ -------------------------------------------------------------------------------- /user_guide/overview/cheatsheets.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | CodeIgniter Cheatsheets : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

CodeIgniter Cheatsheets

59 | 60 |

Library Reference

61 | 62 |
CodeIgniter Library Reference
63 | 64 |

Helpers Reference

65 |
CodeIgniter Library Reference
66 | 67 |
68 | 69 | 70 | 71 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /user_guide/doc_style/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Writing Documentation : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Writing Documentation

59 | 60 |

To help facilitate a consistent, easy-to-read documentation style for CodeIgniter projects, EllisLab is making the markup and CSS from the CodeIgniter user guide freely available to the community for their use. For your convenience, a template file has been created that includes the primary blocks of markup used with brief samples.

61 | 62 |

Files

63 | 64 | 68 | 69 | 70 |
71 | 72 | 73 | 74 | 75 | 85 | 86 | 87 | -------------------------------------------------------------------------------- /user_guide/installation/upgrade_120.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Upgrading From Beta 1.0 to Final 1.2

59 | 60 |

To upgrade to Version 1.2 please replace the following directories with the new versions:

61 | 62 |

Note: If you have any custom developed files in these folders please make copies of them first.

63 | 64 | 73 | 74 |

Please also replace your local copy of the user guide with the new version.

75 | 76 |
77 | 78 | 79 | 80 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /user_guide/general/credits.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Credits : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Credits

59 | 60 |

CodeIgniter was originally developed by Rick Ellis (CEO of 61 | EllisLab, Inc.). The framework was written for performance in the real 62 | world, with many of the class libraries, helpers, and sub-systems borrowed from the code-base of 63 | ExpressionEngine.

64 | 65 |

It is currently developed and maintained by the ExpressionEngine Development Team.
66 | Bleeding edge development is spearheaded by the handpicked contributors of the Reactor Team.

67 | 68 |

A hat tip goes to Ruby on Rails for inspiring us to create a PHP framework, and for 69 | bringing frameworks into the general consciousness of the web community.

70 | 71 |
72 | 73 | 74 | 75 | 85 | 86 | 87 | -------------------------------------------------------------------------------- /system/libraries/Cache/drivers/Cache_apc.php: -------------------------------------------------------------------------------- 1 | $time + $ttl, 121 | 'mtime' => $time, 122 | 'data' => $data 123 | ); 124 | } 125 | 126 | // ------------------------------------------------------------------------ 127 | 128 | /** 129 | * is_supported() 130 | * 131 | * Check to see if APC is available on this system, bail if it isn't. 132 | */ 133 | public function is_supported() 134 | { 135 | if ( ! extension_loaded('apc') OR ini_get('apc.enabled') != "1") 136 | { 137 | log_message('error', 'The APC PHP extension must be loaded to use APC Cache.'); 138 | return FALSE; 139 | } 140 | 141 | return TRUE; 142 | } 143 | 144 | // ------------------------------------------------------------------------ 145 | 146 | 147 | } 148 | // End Class 149 | 150 | /* End of file Cache_apc.php */ 151 | /* Location: ./system/libraries/Cache/drivers/Cache_apc.php */ 152 | -------------------------------------------------------------------------------- /user_guide/helpers/xml_helper.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | XML Helper : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 | 59 |

XML Helper

60 | 61 |

The XML Helper file contains functions that assist in working with XML data.

62 | 63 | 64 |

Loading this Helper

65 | 66 |

This helper is loaded using the following code:

67 | $this->load->helper('xml'); 68 | 69 |

The following functions are available:

70 | 71 |

xml_convert('string')

72 | 73 |

Takes a string as input and converts the following reserved XML characters to entities:

74 | 75 |

76 | Ampersands: &
77 | Less then and greater than characters: < >
78 | Single and double quotes: '  "
79 | Dashes: -

80 | 81 |

This function ignores ampersands if they are part of existing character entities. Example:

82 | 83 | $string = xml_convert($string); 84 | 85 | 86 | 87 | 88 | 89 | 90 |
91 | 92 | 93 | 94 | 103 | 104 | 105 | -------------------------------------------------------------------------------- /user_guide/installation/upgrade_210.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Upgrading from 2.0.3 to 2.1.0 : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Upgrading from 2.0.3 to 2.1.0

59 | 60 |

Before performing an update you should take your site offline by replacing the index.php file with a static one.

61 | 62 |

Step 1: Update your CodeIgniter files

63 | 64 |

Replace all files and directories in your "system" folder and replace your index.php file. If any modifications were made to your index.php they will need to be made fresh in this new one.

65 | 66 |

Note: If you have any custom developed files in these folders please make copies of them first.

67 | 68 |

Step 2: Replace config/user_agents.php

69 | 70 |

This config file has been updated to contain more user agent types, please copy it to application/config/user_agents.php.

71 | 72 | 73 |
74 | 75 | 76 | 77 | 87 | 88 | 89 | -------------------------------------------------------------------------------- /user_guide/general/creating_drivers.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Creating Drivers : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Creating Drivers

59 | 60 |

Driver Directory and File Structure

61 | 62 |

Sample driver directory and file structure layout:

63 | 64 | 78 | 79 |

NOTE: In order to maintain compatibility on case-sensitive file systems, the Driver_name directory must be ucfirst()

80 | 81 | 82 | 83 | 84 |
85 | 86 | 87 | 88 | 98 | 99 | 100 | -------------------------------------------------------------------------------- /user_guide/installation/troubleshooting.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Troubleshooting : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Troubleshooting

59 | 60 |

If you find that no matter what you put in your URL only your default page is loading, it might be that your server 61 | does not support the PATH_INFO variable needed to serve search-engine friendly URLs. 62 | 63 | As a first step, open your application/config/config.php file and look for the URI Protocol 64 | information. It will recommend that you try a couple alternate settings. If it still doesn't work after you've tried this you'll need 65 | to force CodeIgniter to add a question mark to your URLs. To do this open your application/config/config.php file and change this:

66 | 67 | $config['index_page'] = "index.php"; 68 | 69 |

To this:

70 | 71 | $config['index_page'] = "index.php?"; 72 | 73 | 74 |
75 | 76 | 77 | 78 | 88 | 89 | 90 | -------------------------------------------------------------------------------- /system/database/drivers/pdo/pdo_result.php: -------------------------------------------------------------------------------- 1 | result_id->rowCount(); 38 | } 39 | 40 | // -------------------------------------------------------------------- 41 | 42 | /** 43 | * Number of fields in the result set 44 | * 45 | * @access public 46 | * @return integer 47 | */ 48 | function num_fields() 49 | { 50 | return $this->result_id->columnCount(); 51 | } 52 | 53 | // -------------------------------------------------------------------- 54 | 55 | /** 56 | * Fetch Field Names 57 | * 58 | * Generates an array of column names 59 | * 60 | * @access public 61 | * @return array 62 | */ 63 | function list_fields() 64 | { 65 | if ($this->db->db_debug) 66 | { 67 | return $this->db->display_error('db_unsuported_feature'); 68 | } 69 | return FALSE; 70 | } 71 | 72 | // -------------------------------------------------------------------- 73 | 74 | /** 75 | * Field data 76 | * 77 | * Generates an array of objects containing field meta-data 78 | * 79 | * @access public 80 | * @return array 81 | */ 82 | function field_data() 83 | { 84 | $data = array(); 85 | 86 | try 87 | { 88 | for($i = 0; $i < $this->num_fields(); $i++) 89 | { 90 | $data[] = $this->result_id->getColumnMeta($i); 91 | } 92 | 93 | return $data; 94 | } 95 | catch (Exception $e) 96 | { 97 | if ($this->db->db_debug) 98 | { 99 | return $this->db->display_error('db_unsuported_feature'); 100 | } 101 | return FALSE; 102 | } 103 | } 104 | 105 | // -------------------------------------------------------------------- 106 | 107 | /** 108 | * Free the result 109 | * 110 | * @return null 111 | */ 112 | function free_result() 113 | { 114 | if (is_object($this->result_id)) 115 | { 116 | $this->result_id = FALSE; 117 | } 118 | } 119 | 120 | // -------------------------------------------------------------------- 121 | 122 | /** 123 | * Data Seek 124 | * 125 | * Moves the internal pointer to the desired offset. We call 126 | * this internally before fetching results to make sure the 127 | * result set starts at zero 128 | * 129 | * @access private 130 | * @return array 131 | */ 132 | function _data_seek($n = 0) 133 | { 134 | return FALSE; 135 | } 136 | 137 | // -------------------------------------------------------------------- 138 | 139 | /** 140 | * Result - associative array 141 | * 142 | * Returns the result set as an array 143 | * 144 | * @access private 145 | * @return array 146 | */ 147 | function _fetch_assoc() 148 | { 149 | return $this->result_id->fetch(PDO::FETCH_ASSOC); 150 | } 151 | 152 | // -------------------------------------------------------------------- 153 | 154 | /** 155 | * Result - object 156 | * 157 | * Returns the result set as an object 158 | * 159 | * @access private 160 | * @return object 161 | */ 162 | function _fetch_object() 163 | { 164 | return $this->result_id->fetchObject(); 165 | } 166 | 167 | } 168 | 169 | 170 | /* End of file pdo_result.php */ 171 | /* Location: ./system/database/drivers/pdo/pdo_result.php */ -------------------------------------------------------------------------------- /user_guide/helpers/language_helper.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Language Helper : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 48 | 49 | 50 |
51 | 52 | 53 |
54 | 55 | 56 | 57 |
58 | 59 | 60 |

Language Helper

61 | 62 |

The Language Helper file contains functions that assist in working with language files.

63 | 64 | 65 |

Loading this Helper

66 | 67 |

This helper is loaded using the following code:

68 | $this->load->helper('language'); 69 | 70 |

The following functions are available:

71 | 72 |

lang('language line', 'element id')

73 | 74 |

This function returns a line of text from a loaded language file with simplified syntax 75 | that may be more desirable for view files than calling $this->lang->line(). 76 | The optional second parameter will also output a form label for you. Example:

77 | 78 | echo lang('language_key', 'form_item_id');
79 | // becomes <label for="form_item_id">language_key</label>
80 | 81 | 82 |
83 | 84 | 85 | 86 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /user_guide/installation/upgrade_161.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Upgrading from 1.6.0 to 1.6.1 : CodeIgniter User Guide 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | 32 | 33 | 34 |

CodeIgniter User Guide Version 2.1.0

35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 47 | 48 | 49 |
50 | 51 | 52 |
53 | 54 | 55 | 56 |
57 | 58 |

Upgrading from 1.6.0 to 1.6.1

59 | 60 |

Before performing an update you should take your site offline by replacing the index.php file with a static one.

61 | 62 | 63 | 64 |

Step 1: Update your CodeIgniter files

65 | 66 |

Replace these files and directories in your "system" folder with the new versions:

67 | 68 | 76 | 77 |

Note: If you have any custom developed files in these folders please make copies of them first.

78 | 79 |

Step 2: Update your user guide

80 |

Please also replace your local copy of the user guide with the new version.

81 | 82 |
83 | 84 | 85 | 86 | 96 | 97 | 98 | --------------------------------------------------------------------------------