Database Articles
  Home arrow Database Articles arrow Page 5 - Create dynamic sites with PHP & MySQL
Codewalker Forums 
  Tutorials  
Database Articles  
Miscellaneous  
Navigation Usability  
PEAR Articles  
Programming Basics  
Server Administration  
XML Tutorials  
  Reviews  
Database Book Reviews  
Linux Book Reviews  
Miscellaneous Reviews  
PHP Book Reviews  
PHP Software Reviews  
Server Admin Reviews  
SQL Tool Reviews  
  Code Gallery  
Content Management Code  
Contest Code  
Counters Code  
Database Code  
Date Time Code  
Discussion Board Code  
Email Code  
File Manipulation Code  
GUI Code  
Link Farm Code  
Miscellaneous Code  
Search Code  
Site Navigation Code  
User Management Code  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
Download TestComplete 
Forums Sitemap 
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? 
DATABASE ARTICLES

Create dynamic sites with PHP & MySQL
By: Codewalkers
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 25
    2002-05-19

    Table of Contents:
  • Create dynamic sites with PHP & MySQL
  • Introduction and installation
  • Installing Apache server routines
  • Installing MySQL
  • Installing PHP
  • Your first script
  • Your first database
  • Where's my view?
  • Creating an HTML form
  • Putting it together
  • Passing variables
  • Viewing individual rows
  • Deleting rows
  • Editing data
  • Searching our data
  • Tips for common tasks

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb 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


    Create dynamic sites with PHP & MySQL - Installing PHP


    (Page 5 of 16 )

    We will follow a similar procedure to install PHP. Download and save the source from the PHP site to /tmp/ src:

    # cd /tmp/ src/ 
    # gunzip -dc php-x.x.xx.tar.gz | tar xv 
    # cd php-x.x.xx 
    # ./configure --with-mysql=/usr/local/mysql --with-apxs=/usr/local/apache/bin/apxs 
    # make 
    # make install

    Copy the ini file to the proper directory:

    # cp php.ini-dist /usr/local/lib/php.ini

    Open httpd. conf in your text editor (probably located in /usr/local/apache/conf directory), and find a section that looks like the following:

    # And for PHP 4. x, use: 

    #AddType application/x-httpd-php .php 
    #AddType application/x-httpd-php-source .phps

    Just remove those #s before the AddType line so that it looks like:

    # And for PHP 4. x, use: 

    AddType application/x-httpd-php .php .phtml 
    AddType application/x-httpd-php-source .phps

    Save your file and restart apache:

    # /usr/local/apache/bin/apachectl stop 
    # /usr/local/apache/bin/apachectl start

    Then test whether you have PHP installed properly. Type the following code in a text editor and save it as test. php in a directory accessible by your Web server:

    <HTML> 
    <?php 
    phpinfo(); 
    ?> 
    </HTML>

    Set the permission of the file to executable by typing at console chmod 775 test. php, and then view it with your browser. You should see a detailed description of the environment variables in PHP similar to the image below. If you don't, then PHP was not installed properly. Try reinstalling it. Make sure there is a section "MySQL" in the php info; if not, MySQL connectivity will not work.

    More Database Articles Articles
    More By Codewalkers


       · Hi :-)Thank you for this great tutorial!Best regardsU.
       · Very easy to use and follow. There are a few errors with the examples but i found...
       · Well organized, super-clear tutorial.Thanks so much!
       · thanks u for this tutorial it's really user friendly and helpful!=)luvvies,cat
       · I am so glad that I found this tutorial. It has a very comfortable rate of progress...
       · This tutorial sets out to do great things. And when you fix all the code, it really...
       · Hey, you have a few spaces where there not needed, so anyone who gets the...
       · usando esse tutorial você aprende muitas coisas boas sobre mysql e php...
       · 'nuff said
       · its good, but could be made more better by putting more examples
       · I am an idiot among the newbies.Many other tutorials never mention the $_POST[]...
       · Thanks!
       · Congratulations for your hard work to help people like me.This was very important...
       · This helped me get started with mySql and PHP. Thanks a lot!
       · This one of the greatest and most comprehensive tutorials i have read in a long...
       · This one of the greatest and most comprehensive tutorials i have read in a long...
       · 
       · This tutorial helped me make my site for 30 % and 35% exists from databases (= thank...
       · This very useful for me as a new comer. The way tutorial is presented is very...
       · IM KNEELING DOWN IN AWE...MASTER!!! MASTER!!!
     

    DATABASE ARTICLES ARTICLES

    - More on Query Optimization for Oracle Databa...
    - Query Optimization in Oracle
    - Clusters and Other Data Structures for Oracle
    - Using Indexes with an Oracle Database
    - The Basics of Data Structures in Oracle
    - Oracle Data Structures
    - Best Practices for PL/SQL Variables
    - What`s Code Without Variables?
    - Clauses, Sorting, and SQL Queries
    - The From Clause and SQL Queries
    - Query Primer
    - Full Text Searches and Strings
    - Searching with Strings
    - Pattern Matching with Strings
    - Working with Cases of Strings





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