What is PHP?

PHP (Hypertext Preprocessor) is a server-side scripting language used to create dynamic and interactive websites.
It runs on a web server and is widely used for web development.

Explanation:

  • <?php ... ?> → PHP code block
  • echo → used to print text or data(PHP functions not case sensitive).
  • Output will be Hello, World! on your web page.
  • In PHP, keywords (e.g. ifelsewhileecho, etc.), classes, functions, and user-defined functions are not case-sensitive.

How to Run PHP

  1. Install XAMPP or WAMP server(
    • 👉 WWindows→ The operating system.
      👉 AApache → The web server that hosts your site
      👉 MMySQL → The database system to store your data.
      👉 PPHP → The scripting language used to develop web pages)
  2. Save your file as index.php in the htdocs folder
  3. Open your browser → type http://localhost/index.php

Categories: ,

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Posts :-

  • PHP-2

    PHP Variables Rules for PHP variables: PHP supports the following…

  • PHP-1

    What is PHP? PHP (Hypertext Preprocessor) is a server-side scripting…

  • Java OOP-1

    Class Object Blueprint / Template(Plan) Real world entry can’t visual…