PHP Programming Language MCQ Questions Answers – Download 100+ PHP Objective Questions and Answers PDF. Free Study materials for PHP Language. PHP (Hypertext Preprocessor) is a widely-used server-side scripting language designed for web development. It’s a versatile language that allows developers to create dynamic web applications and interact with databases. Whether you’re a beginner looking to test your PHP knowledge or an experienced developer brushing up on your skills, these Multiple Choice Questions (MCQs) with answers will help you gauge your understanding of PHP concepts.
1) PHP is an example of ___________ scripting language.
A) Server-side
B) Client-side
C) Browser-side
D) In-side
2) Which of the following method sends input to a script via a URL?
A) Get
B) Post
C) Both
D) None
3) Who is the father of PHP?
A) Rasmus Lerdorf
B) Willam Makepiece
C) Drek Kolkevi
D) List Barely
4) PHP’s numerically indexed array begin with position __.
A) 1
B) 2
C) 0
D) -1
5) If one intends to create a model that will be assumed by a number of closely related objects, which class must be used?
A) Normal class
B) Static class
C) Abstract class
D) Interface
6) The attack which involves the insertion of malicious code into a page frequented by other users is known as..
A) basic sql injection
B) advanced sql injection
C) cross-site scripting
D) scripting
7) The filesize() function returns the file size in ___.
A) bits
B) bytes
C) kilobytes
D) gigabytes
8) How many functions does PHP offer for searching and modifying strings using Perl-compatible regular expressions.
A) 7
B) 8
C) 9
D) 10
9) Which logging option’s description is, if an error occurs when writing to the syslog, send output to the system console?
A) LOG_CONS
B) LOG_NDELAY
C) LOG_ODELAY
D) LOG_PERROR
10) The updated MySQL extension released with PHP 5 is typically referred to as..
A) MySQL
B) mysql
C) mysqli
D) mysqly