PHP
  Home arrow PHP arrow Building a Database-Driven Application with the Code Igniter PHP Framework
Dev Shed Forums  
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Smartphone Development  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Mobile Linux  
App Generation ROI  
IBM® developerWorks  
Forums Sitemap  
E-Commerce Hosting  
Linux Web Hosting  
Managed Hosting  
Small Business Hosting  
VPS Hosting  
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid  
Request Media Kit
Contact Us  
Site Map  
Privacy Policy  
Support  
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
Google.com  
PHP

Building a Database-Driven Application with the Code Igniter PHP Framework
By: Alejandro Gervasio
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 4
    2008-08-20


    Table of Contents:
  • Building a Database-Driven Application with the Code Igniter PHP Framework
  • Retrieving user-related data from a MySQL table
  • Defining a controller class
  • Outputting user-related data with Code Igniter

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      error-file:tidyout.log Del.ici.ous error-file:tidyout.log Digg
      error-file:tidyout.log Blink error-file:tidyout.log Simpy
      error-file:tidyout.log Google error-file:tidyout.log Spurl
      error-file:tidyout.log Y! MyWeb error-file:tidyout.log Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article

     
     
    ADVERTISEMENT


    Building a Database-Driven Application with the Code Igniter PHP Framework
    ( Page 1 of 4 )

    If you’re a PHP developer who’s searching for a framework that lets you build full-blown web applications very quickly and with an easy learning curve, look no further. Welcome to the second part of the series entitled “Introducing the Code Igniter PHP framework.” This series of articles shows you how to use this friendly yet powerful PHP framework to easily develop database-driven applications by using the Model-View-Controller design pattern.

    Introduction

    Now that you have been introduced to the main subject of this series, it’s time to recall the concepts deployed in the preceding tutorial, in case you haven’t had the chance to read it yet. During that article, I discussed a few basic topics you will need to understand to start using Code Igniter, ranging from how to correctly set up its configuration files and understanding its URL routing mechanism, to developing a sample web application, which made use of the Model-View-Controller approach.

    Put in a simple way, the application was tasked with displaying a trivial message on screen, a process that was performed by way of two source files. The first one was defined as the application’s controller, and the second one was simply a template file, also known as a “view” within the context of the MVC pattern.

    Essentially, the relationship established between these two sample files can be outlined as follows: the controller precisely controls the flow of the application and passes a bunch of data to be embedded into an HTML file to the view, which is finally displayed on screen. That’s all.

    However, this initial sample application was pretty primitive, actually. Therefore, in this second part of the series, I’m going to teach you how to use some core classes bundled with Code Igniter, this time for building a MySQL-driven program, which will first fetch some data from a MySQL database table, and then print this information on the browser.

    As you’ll see in the next few lines, developing this PHP application will require us to define a model class, apart from building the respective controller and view files. Thus, don’t waste more time in preliminaries and begin reading now!



     
     
    >>> More PHP Articles          >>> More By Alejandro Gervasio
     

       

    PHP ARTICLES

    - Getting Data from Yahoo Site Explorer Inboun...
    - Method Chaining: Adding More Selecting Metho...
    - How to Split a File During an FTP Upload Usi...
    - Expanding a Custom CodeIgniter Library with ...
    - Using the Yahoo Site Explorer Inbound Links ...
    - Building a CodeIgniter Custom Library with M...
    - Building an E-mini Trading System Using PHP ...
    - Completing the MySQL Class with Method Chain...
    - Building Dynamic Queries with Chainable Meth...
    - PHP Encryption and Decryption Methods
    - Building a MySQL Abstraction Class with Meth...
    - Completing a Sample String Processor with Me...
    - Mastering WHILE Loops for PHP and MySQL
    - Method Chaining: Adding More Methods to the ...
    - Method Chaining in PHP 5





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 5 Hosted by Hostway
    For more Enterprise Application Development news, visit eWeek