MySQL
  Home arrow MySQL arrow Performing Basic Tasks with MySQL 4.1 and Above, using mysqli with PHP 5
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? 
MYSQL

Performing Basic Tasks with MySQL 4.1 and Above, using mysqli with PHP 5
By: Alejandro Gervasio
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 16
    2006-06-27


    Table of Contents:
  • Performing Basic Tasks with MySQL 4.1 and Above, using mysqli with PHP 5
  • Performing basic operations: connecting to MySQL, running queries and more
  • Leveraging the real power of the “mysqli” extension: running multiple queries
  • Preparing SQL queries: using the “prepare()”, bind_param()” and “execute()” methods

  • 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


    Performing Basic Tasks with MySQL 4.1 and Above, using mysqli with PHP 5
    ( Page 1 of 4 )

    For anyone who has spent a few weeks working with PHP 5, the plethora of cool improvements and new features added to this incarnation of the language has brought a new, more powerful level for developing and deploying Web applications. These include the implementation of exceptions and the brand new object model. But what if I tell you that now you can use PHP 5 to work with MySQL, using an object-oriented approach?

    Introduction

    All right, I know that you're now saying that's not breaking news, since the implementation of objects is an old programming feature. However, PHP 5 has a lot more to offer when it comes to using MySQL. If you're using MySQL 4.1 and above, the good news is that PHP 5 offers a fairly comprehensive extension, called "mysqli," which allows you to interact natively with MySQL via an object-based approach, aside from taking advantage of the new functionality provided by the database server.

    If this subject already caught your curiosity, by using the "mysqli" library in conjunction with MySQL 4.1 and up, you'll be able to execute multiple queries in a single step, and process subsequent result sets. Also, the extension offers other advantages, such as using the "commit" and "rollback" features, all based on an easy-to-grasp object-oriented environment. Using a procedural approach is also possible if you wish.

    As you can see, the "mysqli" library looks really interesting and useful, therefore in this series, I'll be introducing its most important methods and properties, along with the implementation of some advanced approaches, including the features that I mentioned before, and many more handy topics. At the end of the series, you should be equipped with a good background for using "mysqli" together with MySQL 4.1 and above.

    So, let's not waste any more time in preliminaries and start exploring this cool PHP extension. Fun is already guaranteed!



     
     
    >>> More MySQL Articles          >>> More By Alejandro Gervasio
     

       

    MYSQL ARTICLES

    - Null and Empty Strings
    - MySQL Server Tuning Tips and Tricks
    - MySQL Query Optimizations and Schema Design
    - MySQL Benchmarking Tools and Utilities
    - MySQL Benchmarking Concepts and Strategies
    - Take Some Load off MySQL with MemCached
    - MySQL Table Prefix Changer Tool in PHP
    - Using the SIGNAL Statement for Error Handling
    - Error Handling Examples
    - Error Handling
    - Completing a Search Engine with MySQL and PH...
    - Paginating Result Sets for a Search Engine B...
    - Building a Search Engine with MySQL and PHP 5
    - Using Boolean Operators for Full Text and Bo...
    - PHP, MySQL and the PEAR Database





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
    Stay green...Green IT