PHP for beginners

PHP is the leading server site scripting language. Most of the websites are migrating from Cold Fusion, ASP and JSP to PHP. Because the fast, flexibility, database support and so on makes PHP best.

What is PHP?

PHP (PHP Hypertext Preprocessor) Personal Home Pages in earlier days.

PHP cannot run like C, C++ or any other programming languages. PHP is a Server side scripting language. So you have to install and configure a web server with PHP. Apache is the most commonly used web server.

You can download and install Windows/Linux/Mac versions of PHP and Apache. But configuring PHP-Apache won’t be easy for you as a beginner. It is all about editing configuration files and moving files. It may take ages for you to configure and run a “Hello World” programming.
Download WAMP

Best solution for php beginner level programmers .
WAMP Server (Windows Apache MySQL PHP)Download Wamp

Download PHP tutorial in pdf format

Just download and install it. Start your wamp server by left click on wamp icon in system tray (Place where the clock is available in Taskbar) > Apache > Start/Resume Service. This menu item will be disabled one WampApache is running. Ok Lets successfully installed WAMP and started Apache service.You have to understand very basic things about web programming. That is the words LocalHost, Document Root, index page,etc.
Localhost: simply your computer.

You can see what web service is running in your computer. Just open IE (internet Explorer) or Firefox and type http://localhost in the addressbar. You will get an index page about the current localhost. We are currently installed Apache web server with WAMP. So we will get wamp homepage. You can install some other PWS (Personal Web Server) IIS (Internet Information Services) is the default web server for Windows.
My First PHP Program:

Open a text editor.
Start->Run->notepad

<?php
echo(“Hello World”);
?>

Just type the above code and save it as a php file.
Where to save?
You must save all of you PHP files under Root folder. Your document root may be “D:\wamp\www\” folder. So save your file under this folder.

File type?
All PHP files should be saved with the extension (*.php) by default.
Change the “Save as Type” list box’s value in to “All Files” in “Save as” dialogue box. And give the filename “first.php” (without double quotes) and click “Save” button.

Just type http://localhost/first.php in your favorite browser.
Output should be

Hello World.


Once you got this output then your PHP presence is started with cheers!
php tutorials for beginners

Zend.com is having absolute beginner tutorials.
Zend PHP Tutorials
Read all 15 parts and improve your knowledge.




Leave a Comment

You must be logged in to post a comment.

Google