We have listed here the best PHP MCQ Questions for your basic knowledge of PHP. This PHP MCQ Test contains 30 Multiple Choice Questions. You have to select the right answer to every question.
16th Dec, 2020
Q1. PHP’s numerically indexed array begin with position __.
Q2. Which of the functions is used to sort an array in descending order?
Q3. Which of the following PHP function will return true if a variable is an array or false if it is not an array?
Q4. Which of the following array represents an array containing one or more arrays?
Q5. Which of the following function can be used to get an array in the reverse order?
Q6. Which one of the following PHP functions can be used to build a function that accepts any number of arguments?
Q7. The filesize() function returns the file size in ___.
Q8. Which one of the following function is capable of reading a file into a string variable?
Q9. Which function sets the file filename’s last-modified and last-accessed times?
Q10. Which one of the following is the right way of defining a function in PHP?
Q11. The var_dump() function displays
Q12. Which function is used to compare strings as strings in PHP ?
Q13. Which of the following function returns the number of characters in a string variable?
Q14. PHP function arguments are modified in function definition and
Q15. How many ways that PHP offers to modify arguments of a function?
Q16. What is included in phpinfo ( ) function with release of PHP5.2.1 version?
Q17. Which is most important thing in configuration of PHP?
Q18. Which of the following is the way to create comments in PHP?
Q19. Which of the following differences are valid between PHP 4 and PHP 5?
Q20. How do I create PHP arrays in a HTML <form>?
Q21. What is the purpose of $_SESSION?
Q22. What is the difference between echo and print?
Q23. Who is known as the father of PHP?
Q24. PHP scripts are enclosed within _______
Q25. Which of the following method sends input to a script via a URL?
Q26. Which loop evaluates condition expression as Boolean, if it is true, it executes statements and when it is false it will terminate?
Q27. Unbounded loops repeats until some condition becomes
Q28. Loops that iterate for fixed number of times is called
Q29. PHP files have a default file extension of.
Q30. A function in PHP which starts with __ (double underscore) is known as __________