Development - Php Test

Test Instructions :

1. The Test is 1hr duration.
2. The Test Paper consists of 30 questions. The maximum marks are 30.
3. All the questions are multiple choice question type with three options for each question.
4. Out of the three options given for each question, only one option is the correct answer.
5. Each question is allotted 1 mark for each correct response.
6. 0.25 will be deducted for incorrect response of each question.
Start Test

   Time Left : 00 : 30    : 00

Can joins be nested?

  

  

Which directive determines whether PHP scripts on the server can accept file uploads?

  

  

  

  

Which one of the following functions will convert a string to all uppercase?

  

  

  

  

Which one of the following functions is used to search a string?

  

  

  

  

Which one of the following function is used to return an array consisting of various DNS resource records pertinent to a specific domain?

  

  

  

  

How would you start a session?

  

  

  

  

Which one of the following function checks for the existence of DNS records?

  

  

  

  

Which one of the following function should I use to find the parent class of a class?

  

  

  

  

In PHP in order to access MySQL database you will use:

  

  

  

  

Which keyword must be added before $first variable on the third line of the above question to make $second and $first as distinct objects in PHP 5?

  

  

  

  

The ftp_mkdir() function creates a directory on the FTP server.

  

  

  

  

Which of the following are correct ways of creating an array? i) state[0] = “karnataka”; ii) $state[] = array(“karnataka”); iii) $state[0] = “karnataka”; iv) $state = array(“karnataka”);

  

  

  

  

Which one of the following is the default PHP session name?

  

  

  

  

Which one of the following statements is true about sequence diagrams?

  

  

  

  

What is the difference between print() and echo()?

  

  

  

  

  

Which of the following type cast is not correct?

  

  

  

  

In mail($param2, $param2, $param3, $param4), the $param2 contains:

  

  

  

  

Which of the following is/are not an exception? i) BadFunctionCallException ii) BadMethodCallException iii) LogicException iv) DomainException

  

  

  

  

What will be the output if a protected method is given as argument to the function method_exist()?

  

  

  

  

Which one of the following keyword is used in conjunction with an Exception object?

  

  

  

  

Which one of the following filter is used to filter several variables with the same or different filters?

  

  

  

  

Say we have two compare two strings which of the following function/functions can you use? i) strcmp() ii) strcasecmp() iii) strspn() iv) strcspn()

  

  

  

  

Which one of the following method is used to retrieve the number of rows affected by an INSERT, UPDATE, or DELETE query?

  

  

  

  

Multiple select/load is possible with

  

  

  

  

Which of the following can you place inside a namespace?

  

  

  

  

A package is a set of related ___.

  

  

  

  

Which of the following is a PHP resource?

  

  

  

  

What will be the output of the following code? echo 30*5 . 7;

  

  

  

  

  

The FTP functions are used to ....... files from file servers.

  

  

  

  

  

Which one of the following function returns the port number of a specified service?

  

  

  

  

The windows version of PHP has built-in support for the FTP extension

  

  

Which one of the following is not a preg PHP function?

  

  

  

  

The ........... function is used to read a single character from a file.

  

  

  

  

Which datatypes are treaded as arrays

  

  

  

  

The extent to which proximate procedures are related to one another is known as…

  

  

  

  

Which of the following variables does PHP use to authenticate a user? i) $_SERVER['PHP_AUTH_USER'] ii) $_SERVER['PHP_AUTH_USERS'] iii) $_SERVER['PHP_AUTH_PU'] iv) $_SERVER['PHP_AUTH_PW']

  

  

  

  

Which one of the following method is invoked when an undefined method is called by client code?

  

  

  

  

Which one of the following will you use to check the class of an object?

  

  

  

  

Which of the following is/are an external data? i) Cookies ii) Input data from a form iii) Server Variables iv) Web services data

  

  

  

  

Which one of the following preg PHP functions is used to take a string, and put it in an array?

  

  

  

  

The memory_limit is only applicable if ___ is enabled when you configure PHP. Fill in the blank.

  

  

  

  

The date() function returns ___ representation of the current date and/or time.

  

  

  

  

Which one of the following methods recuperates any memory consumed by a result set?

  

  

  

  

To create an object and set the date to JUNE 22, 2013, which one of the following statement should be executed?

  

  

  

  

Which parameter determines whether the old session file will also be deleted when the session ID is regenerated?

  

  

  

  

Which of the following functions do not return a timestamp? 

  

  

  

  

  

What is the difference between stat() and fstat()?

  

  

  

  

  

Which keyword is used to refer to properties or methods within the class itself?

  

  

  

  

Which one of the following filter checks if variable of specified type exists?

  

  

  

  

Which function initializes the constants necessary for using the openlog(), clodelog(), and syslog() functions?

  

  

  

  

Which of the following are valid PHP stream transports? 

  

  

  

  

PHP 4 did not support instanceof. Instead, which function did it provide?

  

  

  

  

How many ways can a session data be stored?

  

  

  

  

What is the default value of max_execution_time directive? This directive specifies how many seconds a script can execute before being terminated.

  

  

  

  

Which function is used to erase all session variables stored in the current session?

  

  

  

  

Since which version of PHP was the directive max_file_limit available.

  

  

  

  

Which of the following is not a predefined constant?

  

  

  

  

  

Before you can start processing images with PHP, you must first add the ability to upload images to your administrative form on ___.

  

  

  

  

Which one of the following methods in the exception class, is used to get a nested exception object?

  

  

  

  

Which of the following are useful for method overloading?

  

  

  

  

Which one of the following functions can be used to concatenate array elements to form a single delimited string?

  

  

  

  

Which class name is reserveed in PHP ?

  

  

  

  

The inbuilt function to get the number of parameters passed is

  

  

  

  

How many configuration directives pertinent to PHP’s mail function are available?

  

  

  

  

Which of the following statements is incorrect with regard to interfaces?

  

  

  

  

When you’re uploading files you need to set the enctype of the form to ___.

  

  

  

  

In PHP programming literal is a

  

  

  

  

Which of the following operations cannot be performed using the standard ftp:// stream wrapper? 

  

  

  

  

What is the default port number of HTTP’s?

  

  

  

  

Which version introduced the function error_get_last()?

  

  

  

  

What array will you get if you convert an object to an array?

  

  

  

  

You need to count the number of parameters given in the URL by a POST operation. The correct way is:

  

  

  

  

Which function effectively deletes all sessions that have expired?

  

  

  

  

Which keyword can be used to fix the above error?

  

  

  

  

The ............. statement is used to delete a table.

  

  

  

  

Which of the following is not supported in PHP5?

  

  

  

  

  

Which one of the following statements should you use to set the session username to Nachi?

  

  

  

  

Which one of the following statements is used to create a table?

  

  

  

  

Which one of the following method is invoked when a value is assigned to an undefined property?

  

  

  

  

Which one among the following means tight coupling ?

  

  

  

  

Which keyword is used to put a stop on inheritance?

  

  

  

  

Which one of the following does not describe a validating filter?

  

  

  

  

What functions count elements in an array?

  

  

  

Which function displays the web page’s most recent modification date?

  

  

  

  

___ are used in class diagrams to describe the way in which specific elements should be used.

  

  

  

  

Which directive determines which degree of server details is provided if the ServerSignature directive is enabled?

  

  

  

  

UML stands for?

  

  

  

  

Which of the following statements is used to add an attachment to the mail?

  

  

  

  

Which function is responsible for sending a custom message to the system log?

  

  

  

  

Which version of PHP introduced E_STRICT Error level?

  

  

  

  

If the diamond is filled it depicts which relationship?

  

  

  

  

Say I want to change the extension of a PHP file, which of the following statements should I edit to change from .php to .html in the httpd.conf file?

  

  

  

  

Placing a static method for generating ___ objects in the ___ class is convenient.

  

  

  

  

The filesize() function returns the file size in ___.

  

  

  

  

How many types of filtering are present in PHP?

  

  

  

  

A bidirectional relationship in class diagrams is described by..

  

  

  

  

Study following steps and determine the correct order (1) Open a connection to MySql server (2) Execute the SQL query (3) Fetch the data from query (4) Select database (5) Close Connection

  

  

  

  

What does PHP stand for? i) Personal Home Page ii) Hypertext Preprocessor iii) Pretext Hypertext Processor iv) Preprocessor Home Page

  

  

  

  

Which one of the following function is used to send a e-mail using PHP script?

  

  

  

  

If you call a method and it doesn’t exist it’ll cause a problem. To check the method which function will you use?

  

  

  

  

Note:
  • Click the 'Submit Test' button given in the bottom of this page to Submit your answers.
  • Test will be submitted automatically if the time expired.
  • Don't refresh the page.