• PHP interview Question

  • PHP developer interview Question

1) What is PHP?

PHP is a open source server side scripting  language  that allow developers to dynamically create generated web pages and web application.

2) What is the full name of the php?

PHP means PHP: Hypertext Preprocessor.

3) Which programming language does PHP resemble?

PHP syntax resembles Perl and C

4) What does PEAR stand for?

PEAR means “PHP Extension and Application Repository”. It extends PHP and provides a higher level of programming for web developers.

5) What is the actually used PHP version?

Version 7.1 or 7.2 is the recommended version of PHP.

6) How do you execute a PHP script from the command line?

Just use the PHP command line interface (CLI) and specify the file name of the script to be executed as follows:

php script.php

7) How to run the interactive PHP shell from the command line interface?

Just use the PHP CLI program with the option -a as follows:

php -a

8) What is the correct and the most two common way to start and finish a PHP block of code?

The two most common ways to start and finish a PHP script are:

 <?php [   ---  PHP code---- ] ?> and <? [---  PHP code  ---] ?>

Q9. What are uses of include() and require() functions in php?

The Include() function is used to put data of one PHP file into another PHP file. If errors occur then the include() function produces a warning but does not stop the execution of the script and it will continue to execute.

The Require() function is also used to put data of one PHP file to another PHP file. If there are any errors then the require() function produces a warning and a fatal error and stops the execution of the script.

Q10.What are different types of errors show in php?

The different types of error in PHP show are

1- E_NOTICE– Run time notice caused due to error in code.

2- E_ERROR– A fatal error that causes script termination.

3- E_PARSE– Compile time parse error.

4- E_WARNING– Run-time warning that does not cause script termination.

Q11.What is the coockie in PHP?

A coockie is often used to identity a user.A coockie is a small file that the server embed on the users computer.

Q12.What is the sessions in PHP?

A session is used to store information about or change setting for a session user .session hold information about one single user ,and are avaliable to all page in one application.

Q13.Types of loop in PHP?

Types of loop in php are





Q 14.How is the father of PHP?

Rasmus lerdorf is the father of php.

Q 15.Diffrence between echo and print?

Echo= echo can output one or more strings.

print = print can only output one strings , and return always.

Q 15.How many data types in php?

1-String ,Integer , Floating, point Numbers, Boolean, Array, Object,



Leave a Comment

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