Q. What is the valid set of characters (or, metacharacters) to find the Unicode character specified by the hexadecimal number xxxx?

  • (A) \uxxxx
  • (B) \xxxx
  • (C) \+uxxxx
  • (D) \+Uxxxx
πŸ’¬ Discuss
βœ… Correct Answer: (A) \uxxxx

Q. What is the complete syntax of PHP date() function?

  • (A) date(format)
  • (B) date(timestamp)
  • (C) date(format, timestamp)
  • (D) date(format, value, timestamp)
πŸ’¬ Discuss
βœ… Correct Answer: (C) date(format, timestamp)

Q. Which is the correct PHP statement to print the current date in DD-MON-YYY format?

  • (A) <?php echo date("DD-MON-YYYY"); ?>
  • (B) <?php echo date("dd-mon-yyyy"); ?>
  • (C) <?php echo date("d-m-y"); ?>
  • (D) <?php echo date("d-M-Y"); ?>
πŸ’¬ Discuss
βœ… Correct Answer: (D) <?php echo date("d-M-Y"); ?>

Q. What will be the output of the following PHP code (if the date is 30th December 2021)?

  • (A) 30th - Dec - 2021
  • (B) 30 (Thursday) - Dec - 2021
  • (C) 30 (Thu) - Dec - 2021
  • (D) 30 (l) - Dec - 2021
πŸ’¬ Discuss
βœ… Correct Answer: (B) 30 (Thursday) - Dec - 2021

Q. Which is the correct PHP statement to print the current time in the format of hour:minutes:seconds(am/pm) i.e., 10:22:54pm?

  • (A) <?php echo date("h:i:sa");?>
  • (B) <?php echo date("h:m:sa");?>
  • (C) <?php echo date("h:mi:sa");?>
  • (D) <?php echo date("hh:min:sa");?>
πŸ’¬ Discuss
βœ… Correct Answer: (A) <?php echo date("h:i:sa");?>

Q. PHP is a ............

  • (A) Open Source Laguage
  • (B) Widely Used Language
  • (C) Server side scripting language
  • (D) All of the above
πŸ’¬ Discuss
βœ… Correct Answer: (D) All of the above

Q. Which of the following symbol is used to add multiple line comments in PHP ?

  • (A) //
  • (B) /* */
  • (C) {{ }}
  • (D) {/ \}
πŸ’¬ Discuss
βœ… Correct Answer: (B) /* */

Q. Which sign is used to access variable of variable in PHP?

  • (A) $$
  • (B) $
  • (C) #@
  • (D) $|
πŸ’¬ Discuss
βœ… Correct Answer: (A) $$

Q. Which of following is not a Superglobals in PHP?

  • (A) $_SERVER
  • (B) $_ENV
  • (C) $_FILES
  • (D) $_PUT
πŸ’¬ Discuss
βœ… Correct Answer: (D) $_PUT

Q. Which function is used to get ASCII value of a character in PHP ?

  • (A) asc()
  • (B) chr( )
  • (C) ascii()
  • (D) val( )
πŸ’¬ Discuss
βœ… Correct Answer: (B) chr( )