PHP Variables

Like in any other programming language, in PHP a variable is also used to dedicate some memory space to store some data.

Things to Remember...
  • The variable name must be a alpha-nemeric or may include underscores.
  • After $ sign the variable name should have letter or underscore i.e a variable name must not start with a numeric value.
  • Spaces are not allowed.


Adding PHP in HTML

In this little post,i will explain different methods of inserting PHP code in HTML, so the PHP interpreter can identify the PHP scripts embedded in HTML.


The PHP Development Environment


You write the PHP code in any editor and save it as .php file.Than this page is requested through a webserver software
such as apache.This webserver software than calls the php interpreter to process this .php file for us and dislay it on
browser unlike the static html pages which just requires a browser to show its data.
Now the problem is that setting up this environment is not so easy you have to go through the following processes.
1.Download and intall Apache.
2.Download and intall PHP and also configure it with Apache.
3.Download and install MySQL database management system.
Alternatively and recommendedly just go to this url and install wamp server which is a simple arrangement for all
these tools and its installation is fairly simple.