18 real Superglobals & Web questions from the PHP bank, as asked in Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd — free to start.
1. What is Superglobal?
Junior
A.an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
B.the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
C.a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
D.a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration
2. Which term means: "a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration"?
A.Superglobal — the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
B.Superglobal — an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
C.Superglobal — a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
D.Superglobal — a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration
A.the function that creates a secure salted one-way digest of a plaintext credential using a strong adaptive algorithm such as bcrypt by default
B.the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
C.an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
D.a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
5. Which term means: "a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie"?
A.Session — an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
B.Session — a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
C.Session — a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
D.Session — a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration
A.an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
B.a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
C.the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
D.a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
8. Which term means: "a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure"?
A.Prepared statement — a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
B.Prepared statement — a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
C.Prepared statement — an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
D.Prepared statement — a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration
A.a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
B.an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
C.the function that creates a secure salted one-way digest of a plaintext credential using a strong adaptive algorithm such as bcrypt by default
D.the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
11. Which term means: "the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL"?
A.PDO — an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
B.PDO — a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
C.PDO — the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
D.PDO — a server-side mechanism that persists user data across multiple requests by linking them through an identifier carried in a cookie
A.the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
B.the function that creates a secure salted one-way digest of a plaintext credential using a strong adaptive algorithm such as bcrypt by default
C.an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
D.a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
14. Which term means: "the function that creates a secure salted one-way digest of a plaintext credential using a strong adaptive algorithm such as bcrypt by default"?
A.password_hash — the function that creates a secure salted one-way digest of a plaintext credential using a strong adaptive algorithm such as bcrypt by default
B.password_hash — a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration
C.password_hash — the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
D.password_hash — a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
A.an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
B.a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration
C.the function that creates a secure salted one-way digest of a plaintext credential using a strong adaptive algorithm such as bcrypt by default
D.a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
17. Which term means: "an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars"?
A.Cross-site scripting — an injection flaw where unescaped attacker input is rendered as active markup in a victim's browser, mitigated by output encoding with htmlspecialchars
B.Cross-site scripting — a precompiled SQL template whose user values are sent separately as bound parameters, neutralising injection by keeping data out of the query structure
C.Cross-site scripting — a built-in associative array such as the GET or POST array that is automatically available in every scope without an import or global declaration
D.Cross-site scripting — the object-oriented database abstraction layer offering one consistent API with prepared statements across many drivers like MySQL and PostgreSQL
Answers, AI explanations, and a scored voice mock interview
Sign up free to check your answers with explanations, ask the AI tutor anything on any question, and take one full AI mock interview — scored like a real panel.