Chapter1.Essential PHP


Chapter 1. Essential PHP

Welcome to PHP! "PHP" officially stands for "PHP: Hypertext Preprocessor," but millions of people still know it by its original name, Personal Home Page, and that's what it's all aboutcreating your own interactive web pages in the easiest possible way. No longer will web pages have to be static, unchanging things. Now you can send the user new web pages tailored to what he or she wants to see in real time. You can handle button clicks, checkbox selections, and radio buttons and can even draw graphics interactively and store data in a database. It's all up to youthe lid is off the box.

This is where you make your web pages come alive.

We'll be using PHP version 5, whose web site is www.php.net, in this book. PHP is specially designed to make creating your own web pages a snap. In this book, we're going to work from the server side by installing PHP scripts on your web server. Users will be able to open those scripts in a web browser, seeing everything they'd expect from a fully fledged page: text fields, tables full of data created on-the-fly from databases, and fluid graphicseverything you might see on the most professional interactive web page is now within your grasp.

With static web pages written in simple HTML, a web server will just pass the HTML in a web page back to the browser, and the user can see pictures and text, but that's about it. When you write sever-side scripts in PHP, on the other hand, you actually tell the server what you want to doread what the user entered in a text field, see which checkboxes were clicked, and so on. Then you can decide what to do next, and you can create the web page to send back on-the-fly. That's the name of the game herebeing able to respond dynamically.

PHP has become a huge successmore than 15 million web pages use it now. In the following pages, we'll see how to make the web server do what we want with PHP.



    Spring Into PHP 5
    Spring Into PHP 5
    ISBN: 0131498622
    EAN: 2147483647
    Year: 2006
    Pages: 254

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net