Skip to main content

Beginning with PHP development with your first php code.

PHP is a server scripting language that is mainly suitable for web page or web application development. PHP pages can also have HTML, CSS and Javascript  in it. By default PHP can be write in a file with .php extension like 'filename.php'.

System Requirements  for PHP Development:

(On Window OS)

The all in one solution for PHP development on window machine are : WAMP and XAMPP server stack that have web server (Apache) , PHP and database server (Mysql) in it.

You can download WAMP server from here or the XAMPP server from here.

One of the best thing with these server is that they are open source and free to use.

Tools you can use:

Notepad++ : This is a text editor that can be used to write your PHP code.

Download the Notepad++ from here.


Step to write you first PHP code:
  • Install the WAMP/XAMPP server.
  • Create a new file in Notepad++ (Or any text editor you have)
  • Write the below code in the file.
Code of index.php file
  • Save the file as "index.php" in the C:\wamp\www\ folder in WAMP server or C:\xampp\htdocs\ folder in XAMPP server. 
  • Go to web browser like Mozilla or Internet Explorer.
  • Write http://localhost/index.php in the address bar.
That done  you will see the following output.
Output of index.php file

Enjoy your first php code. Happy coding :)

Comments

Popular posts from this blog

The Great Architectures of Bijawar, Chhatarpur, M.P.

Bijawar, Temple Janki Niwash Bijawar, Temple Janki Niwash   Maharaja Palace of Bijawar - A very royal palace of the Great Maharaja Ji of Bijawar. The palace has a great eye caching architecture. It stands tall with its mirror image on a big Talab in front of it. The palace is become very old and loosing its age at a rapid pace. Unfortunately its to late to restore the Bijawar palace infrastructure but one should create Bijawar palace replica or model to preserve its beauty and architecture. This photo of the palace is the first photo taken and publish on the web. That time there was no good cameras available but as said Old is Gold.

You are running 'create-react-app' 4.0.3 which is behind the latest release (5.0.1).

I was trying to create a new React app with the following command. > npx create-react-app react-app Then I get the following error: You are running `create-react-app` 4.0.3, which is behind the latest release (5.0.1). We no longer support global installation of Create React App. I also get some help instructions as well as: Please remove any global installs with one of the following commands: - npm uninstall -g create-react-app - yarn global remove create-react-app I tried to run the floowing command multiple times as suggested: > npm uninstall -g create-react-app Which ran fine with no error that means my create-react-app glabal installation uninstalled successfully. Then I again tried the same command to install the React app: > npx create-react-app react-app But I again get the same errors and suggestions. I repeated the same procedure multiple times but it did not work. Then I decided to look for the solution over a search engine. By no much time, I got some useful help th...

Python Program To Find the Modulus with using modulus operator

  def cal_mod(dividend, divisor): # check the max divisor power of the dividend dividend_power = 1 while dividend > (divisor ** dividend_power) : dividend_power += 1 # reduce the dividend to the divisor_power + 1 # if dividend_power is greater then 2 if dividend_power > 2: while dividend > (divisor ** 2): dividend = cal_mod(dividend, (divisor ** (dividend_power - 1) )) dividend_power -= 1 while dividend >= divisor: dividend = dividend - divisor return dividend result = cal_mod(45645664566465456456878756765675699788866264623874682464, 16) print(result)