Topic / 29 questions

PHP MCQs

PHP MCQs test knowledge of PHP, the server-side scripting language widely used to build websites, covering its history, string functions, predefined variables and form handling with GET and POST. They help computer science students, web developers and IT job applicants. Every question shows its correct answer instantly, so you can check your knowledge quickly.

Advertisement
Advertisement
Advertisement

About PHP MCQs

This short set covers PHP basics. Questions ask who created PHP, Rasmus Lerdorf, and what the name stands for today, the recursive PHP: Hypertext Preprocessor. You will also find items on PHP as a server-side scripting language, string functions such as strlen(), which returns the length of a string, and ucwords(), which capitalises the first letter of each word. Other questions cover predefined variables such as $_GET and $_POST, and the GET method, which sends form data through the URL. These are common in web development interviews and IT job tests.

Exams that include PHP MCQs

Pakistan

  • NTS
  • PPSC Lecturer tests
  • FPSC

India

  • Campus placements
  • UGC NET

Bangladesh

  • Government job tests
  • BCS

Frequently asked questions

What does PHP stand for?

PHP now stands for PHP: Hypertext Preprocessor, a recursive acronym. It originally meant Personal Home Page when Rasmus Lerdorf created it in the mid-1990s. PHP runs on the web server and generates HTML that is sent to the browser.

What is the difference between GET and POST in PHP?

GET sends form data as part of the URL, so it is visible, limited in length and suitable for searches or bookmarks. POST sends data in the body of the HTTP request, so it is not shown in the URL and suits passwords, file uploads and larger data. PHP reads them through $_GET and $_POST.

Last reviewed October 2026