• Courses
  • Tutorials
  • DSA
  • Data Science
  • Web Tech
Switch to Dark Mode

PHP Quiz | Set-1

Last Updated : Apr 2, 2024
Discuss
Comments

Question 1

Full form of PHP is______
  • A
    Hypertext Preprocessor
  • B
    Pretext Hypertext Preprocessor
  • C
    Processor Hypertext Processor
  • D
    None of the above

Question 2

The default file extension in PHP are ____

  • A

    .php

  • B

    .css

  • C

    .js

  • D

    .html

Question 3

Which of the following is the correct way to declare the constant in PHP?
  • A
    const
  • B
    define
  • C
    var
  • D
    let

Question 4

How does the name of the variable in PHP starts?
  • A
    Sign !
  • B
    Sign $
  • C
    Sign &
  • D
    Sign #

Question 5

Which of the following is the syntax of comment in PHP?

  • A

    /* */

  • B

    #

  • C

    //

  • D

    All of the above

Question 6

If you want to add write the PHP code which of the below code editor is used?

  • A

    Notepad++

  • B

    Sublime

  • C

    Visual code

  • D

    All of the above

Question 7

Which of the below method is used to generate the unique id in Php?

  • A

    unique()

  • B

    id()

  • C

    mid()

  • D

    None of the above

Question 8

Which of the following is the correct way to concrete() the two strings in PHP?
  • A
    .
  • B
    +
  • C
    Append
  • D
    All of the above

Question 9

Which of the below is the correct syntax for opening the given file in PHP?

"geeky.txt"
  • A

    fopen("geeky.txt", "r");

  • B

    fopen("geeky.txt", "w");

  • C

    fopen("geeky.txt", "read");

  • D

    fopen("geeky.txt");

Question 10

Which of the below function display the configuration in PHP?
  • A
    php_display()
  • B
    phpinfo()
  • C
    info_config()
  • D
    None of the above

Ready to go from coding beginner to development pro? Our DSA to Development Coding Guide has everything you need to crush coding interviews and ace real-world projects! Limited spots available!
Enroll Now and Transform Your Coding Skills! Also get 90% fee refund on completing 90% of the course in 90 days! Take the Three 90 Challenge today.

There are 15 questions to complete.

Take a part in the ongoing discussion