PHP First Program

PHP First Program

After installing PHP successfully on Windows, we learned how to run our first PHP program. Now, we will see another example and learn some more concepts about a PHP program. Our PHP first program will also explain the concepts of programming in PHP, which will further help in working with PHP program in the upcoming lessons.

PHP program consists of the following tags:

  • <?php = start tag
  • ?> = end tag
  • ; = statements in PHP ends with a semi-colon

PHP tags Overview

PHP files default extension is .php and a PHP program consist of the following:

  • PHP scripting code
  • HTML tags

Here’s our first program,

As you can see above, the output, Hi, Our first PHP program! will print, since echo is a built-in function that prints text.

PHP First program Output

PHP Installation on localhost
PHP Variables
Studyopedia Editorial Staff
Studyopedia Editorial Staff
[email protected]

We work to create free tutorials for all.

No Comments

Post A Comment