Posted on Leave a comment

php interview questions and answers for experienced | php interview

php multiple choice questions and answers code,

Another new MCQ Questions with Answer on the category of PHP (Php Hypertext Preprocessor). In this set you will get 10 Objective Questions with Answer related to Php Hypertext Preprocessor (PHP). Four options are given to each questions as possible answer but only one option is the correct one, select your answer and tally with the given correct answer. Correct answer are given below of this Questions Set. (

2-1. What is the use of strlen( ) function in PHP?
A. It returns the type of a string
B. It returns the value of a string
C. It returns the length of a string
D. It returns the subset value of a string

2-2. Which of the following is the Concatenation Operator in PHP?
A. + (Plus)
B. . (dot)      
C. & (Ampersand)
D. % (Percentage)

2-3. Which of the following is not PHP Loops?
A. while
B. do while
C. for
D. do for

2-4. What is the use of strpos( ) function in PHP?
A. Search for a number within a string
B. Search for a Spaces within a string
C. Search for a character/text within a string
D. Search for a Capitalized string/text with in a string

2-5. Where setcookie( ) function must appear in PHP?
A. Before tag
B. After tag
C. In tag
D. Anywhere

2-6. What does the hash (#) sign mean in PHP?
A. It indicates lines that are commented out.
B. It indicates variable declaration.
C. It indicates function declaration.
D. No uses in PHP.

2-7. How to define a variable in PHP?
A. $variable_name = value
B. $variable_name = value;
C. $variable_name == value;
D. $variable_name as value;

2-8. The uses of strcmp( ) function in PHP?
A. It compare strings including case
B. It compare strings excluding case
C. It compare strings only Uppercase
D. It compare strings only lowercase

2-9. What will be the result of combining a string with another data type in PHP?
A. int
B. float
C. string
D. double

2-10. Data for a cookie stored in _________ in PHP?
A. In ISP Computer
B. In User’s Computer
C. In Server Computer
D. It depends on PHP Coding

Click Here for Answers1 – C / 2 – B / 3 – D / 4 – C / 5 – A / 6 – A / 7 – B / 8 – A / 9 – C / 10 – B

Leave a Reply

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