Ktl-icon-tai-lieu

tài liệu codeigniter

Được đăng lên bởi trongdai306-gmail-com
Số trang: 18 trang   |   Lượt xem: 311 lần   |   Lượt tải: 0 lần
CodeIgniter and MVC
Enterprise class web application development

Dienstag, 4. Mai 2010

Motivation
• You have worked with PHP, for small sites this works very well. HTML files
can be easily extended with dynamic content from the database, form
processing, etc.
• When sites grow, you might have realized that across multiple pages lots of
code repetition occurs. This is a problem when you need to change certain
parts of a page, that affects many or all pages.
• Furthermore, its hard to introduce new developers to code someone else
has written. It takes a long time to get familar with the code.

Dienstag, 4. Mai 2010

Motivation
• Enterprise class (big) web applications need structure, one HTML file per
page with PHP code is not optimal => things get confusing, hard to work in
teams, etc.
• Web Application Frameworks provide such a structure wich introduce
seperation of concern, etc.
• Most common for Web application development are frameworks that are
based on the Model-View-Controller design pattern
• Motivation video for a MVC framework:


Dienstag, 4. Mai 2010

Model-View-Controller
• „Seperation of concerns“ of Logic and Presentation
• Controller: Handles all incoming HTTP requests, passes data to the views
• View: Renders the HTML output
• Models: Encapsulate Business Logic, such as interaction with the database
• For PHP we introduce CodeIgniter

Dienstag, 4. Mai 2010

CodeIgniter
• CodeIgniter is a PHP-based MVC framework that helps structure your code
and make redundant tasks less tedious.
• There are countless similar PHP frameworks, the most popular ones being
CakePHP and symfony. Ruby on Rails is famous in the Ruby world.
• CodeIgniter is very light weight. It doesn‘t force any convention but provides
many commonly required features through a set of build in libraries.
• CodeIgniter has a low learning curve and is one of the best documented PHP
web frameworks.

Dienstag, 4. Mai 2010

CodeIgniter: Features
• Model-View-Controller Based System
• Extremely Light Weight, does not force any convention
• Full Featured database classes with support for several platforms,
Active Record Database Support (ORM)
• Custom Routing
• Form and Data Validation
• Security and XSS Filtering

Dienstag, 4. Mai 2010

Application Flow Chart

1. The index.php serves as the front controller, initializing the base resources needed
to run CodeIgniter.
2. The Router examines the HTTP request to determine what should be done wi...
CodeIgniter and MVC
Enterprise class web application development
Dienstag, 4. Mai 2010
tài liệu codeigniter - Trang 2
Để xem tài liệu đầy đủ. Xin vui lòng
tài liệu codeigniter - Người đăng: trongdai306-gmail-com
5 Tài liệu rất hay! Được đăng lên bởi - 1 giờ trước Đúng là cái mình đang tìm. Rất hay và bổ ích. Cảm ơn bạn!
18 Vietnamese
tài liệu codeigniter 9 10 957