Friday, 22 April 2011

PHP Introduction and Files



PHP Introduction and Files

PHP stands for personal homepage and implemented by Rasmus Lerdorf in1950. 
The alias name of PHP is Hypertext Preprocessor
.
Wamp: Wamp is an environment to work with the php and wamp stands for windows apache mysql and php.

Lamp: Lamp stands for linux, apache, mysql and php.

Xampp: Xampp stands for any operating system. It supports different types of operating systems. The latest version of Xampp is 1.8.

*Install Xampp

After installation of Xampp a folder is available in destination location with the name. Xampp contains number of sub folder.
After the installation we have to start the ‘Apache’ server by using xampp control panel.
To check whether the Xampp is installed successfully or not, open the browser and type “http//localhost/xampp”. If you can see the xapmm icon it means Xapmm is successfully installed.

htdocs: This is the document root php application. Web server searches the requested file from this server.

tmp: This is the temporary location to maintain the session data and upload files.

Php: This folder contains php configuration settings. Php.ini is a file contains the all configuration directives (settings).

Apache: This folder contains the Apache configuration settings.

httpd.conf: This is apache configuration setting files.

Phpmyadmin: It is an environment to work with the Mysql data base.

Mysql: This folder contains the Mysql configuration settings My.cnf. My.cnf is a file contains configuration directives.

Open note pad and type below script , save the file with extension ‘.php’ and save in ‘htdocs’ folder whoch is located in xampp folder.


Sample Script:
<?php
print(“welcome”);
?>

By default Apache server port number is ‘80’. To change the port number , we have to change the values of 2 configurations. Listen and server name local host.
When we modify the values of configuration directives, we have to save that file and restart the web server.
To change the document root of web server, change the values of 2 directives. One is document root and another one is directive.

2 comments:

  1. sir How can we create a pop up using java script to stop when user want to exit the page????

    ReplyDelete
  2. image insertion in database and retrieval and display...can any body help me...

    ReplyDelete