Archive for the ‘PHP & MySQL’ Category

Creating PHP Variables

That’s not a typoPHP lets you create variable variables. A variable variable is one that holds the name of a variable. Here’s how it works: you create a variable named, say, $apples:

Posted on Jun 26, 2008

Running PHP on the Command Line

If php is in your path, you can run this from the command line like so (where % is a generic, cross-platform command-line prompt, and this example assumes you’re in the same directory as echo.php):

Posted on Jun 26, 2008

Mixing PHP in Some HTML

PHP files are most often mixtures of HTML and PHP scripts. Putting HTML and PHP scripts into the same document is no problem because you put your PHP statements inside a script bounded by <?php and ?>, which means the server can pick them out easily.

Posted on Jun 26, 2008

Creating Your First PHP Script

Here’s where all the action startscreating your first PHP scripts. With PHP, which will be run on the web server, you can make all kinds of things happen that couldn’t happen before. You can have your PHP retrieve data from databases, check someone’s password, print out customized greeting text, use cookies, write a guest book, [...]

Posted on Jun 26, 2008

Getting 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 [...]

Posted on Jun 26, 2008