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

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?

  

  

  

  

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

  

  

  

  

  

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

  

  

  

  

Inheritance in class diagrams is depicted by..

  

  

  

  

Which of the following functions do not return a timestamp? 

  

  

  

  

  

Which one of the following databases has PHP supported almost since the beginning?

  

  

  

  

Select the incorrect statement about PHP programming language

  

  

  

  

What is the default value of max_input_time directive?

  

  

  

  

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

  

  

  

  

What functions count elements in an array?

  

  

  

Which relationship is illustrated by a line that begins with an unfilled diamond?

  

  

  

  

___ occurs when discrete parts of a system’s code are tightly bound up with one another so that a change in one part necessitates changes in the others.

  

  

  

  

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

  

  

  

  

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?

  

  

  

  

Suppose all web material is located within the directory /home/www. To prevent users from viewing and manipulating files such as /etc/password, which one of the following statements should you use?

  

  

  

  

Which of the following can you place inside a namespace?

  

  

  

  

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

  

  

  

  

__clone() is run on the ___ object.

  

  

  

  

Till which version of PHP, developers were forced to name their files in a global context?

  

  

  

  

Which one among the following means tight coupling ?

  

  

  

  

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

  

  

  

  

Can joins be nested?

  

  

You are using sessions and session_register() to register objects. These objects are serialized automatically at the end of each PHP page and are de-serialized automatically on each of the following pages. Is this true or false?

  

  

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

  

  

  

  

How many error levels are available in PHP?

  

  

  

  

PHP provides built-in interceptor methods, which can intercept messages sent to undefined methods and properties. This is also known as ___.

  

  

  

  

Which one of the following preg PHP function is used to do a find and replace on a string or an array?

  

  

  

  

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

  

  

  

  

The inbuilt function to get the number of parameters passed is

  

  

  

  

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

  

  

  

  

Which logging option’s description is, if an error occurs when writing to the syslog, send output to the system console?

  

  

  

  

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

  

  

  

  

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”);

  

  

  

  

What is the description of Error level E_ERROR?

  

  

  

  

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

  

  

  

  

In PHP language PEAR stands for

  

  

  

  

How many predefined exceptions does SPL provide access to?

  

  

  

  

What will happen at the end of the following sequence of SQL commands?   BEGIN TRANSACTION DELETE FROM MYTABLE WHERE ID=1 DELETE FROM OTHERTABLE ROLLBACK TRANSACTION  

  

  

  

  

  

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

  

  

  

  

Which one of the following function is used to retrieve the MX records for the domain specified by hostname?

  

  

  

  

If the diamond is filled it depicts which relationship?

  

  

  

  

We can use ___ to comment a single line? i) /? ii) // iii) # iv) /* */

  

  

  

  

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

  

  

  

  

Which one of the following statements should be used to include a file?

  

  

  

  

A PHP script should start with ___ and end with ___:

  

  

  

  

Which one of the following statements is true for include_once() and require_once()?

  

  

  

  

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

  

  

Which of the following is a PHP resource?

  

  

  

  

Which function is used to transform PHP’s session-handler behavior into that defined by your custom handler?

  

  

  

  

___ occurs when discrete parts of a system’s code are tightly bound up with one another so that a change in one part necessitates changes in the others.

  

  

  

  

Which one of the following is know as the key to object-oriented programming ?

  

  

  

  

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

  

  

  

  

What does SPL stand for?

  

  

  

  

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

  

  

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

  

  

  

  

Which of the following type cast is not correct?

  

  

  

  

Which of the following are useful for method overloading?

  

  

  

  

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

  

  

  

  

Under what circumstance is it impossible to assign a default value to a parameter while declaring a function?

  

  

  

  

  

Which function was introduced to help automate the inclusion of class files?

  

  

  

  

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

  

  

  

  

Which one of the following statements can be used to establish port 80 connection with www.google.com?

  

  

  

  

Variables/functions in PHP don't work directly with

  

  

  

  

A bidirectional relationship in class diagrams is described by..

  

  

  

  

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

  

  

  

  

+ is the visibility code for?

  

  

  

  

Which of the following multithreaded servers allow PHP as a plug-in?

  

  

  

  

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

  

  

  

  

Say you want to report error concerned about fatal run-time, fatal compile-time error and core error which statement would you use?

  

  

  

  

Which symbol is used to declare nested namespaces?

  

  

  

  

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

  

  

  

  

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

  

  

  

  

  

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

  

  

  

  

Which datatypes are treaded as arrays

  

  

  

  

A package is a set of related ___.

  

  

  

  

Which one of the following functions finds the last occurrence of a string, returning its numerical position?

  

  

  

  

Which version of PHP introduced Try/catch Exception?

  

  

  

  

In a class diagram the class is divided into three sections, what is displayed in the first section?

  

  

  

  

Which of the following is not a predefined constant?

  

  

  

  

  

Which of the following is not supported in PHP5?

  

  

  

  

  

which of the following is a correct declaration?

  

  

  

  

Which of the following DBMSs do not have a native PHP extension?

  

  

  

  

  

Which of the following printing construct/function accpets multiple parameters?

  

  

  

  

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

  

  

  

  

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

  

  

  

  

Which of the following is a single global function defined in the jQuery library?

  

  

  

  

Which one of the following is displayed below the class name in the class diagrams?

  

  

  

  

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

  

  

  

  

  

How would you store order number (34) in an 'OrderCookie'?

  

  

  

  

# is the visibility code for?

  

  

  

  

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

  

  

  

  

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

  

  

  

  

Which of the following is/are an exception? i) OutOfBoundException ii) OutOfRangeException iii) OverflowException iv) UnderflowException

  

  

  

  

which of the following pair have non-associative equal precedence?

  

  

  

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

  

  

  

  

Object-oriented code tries to minimize dependencies by moving responsibility for handling tasks away from ___ and toward the objects in the system.

  

  

  

  

Which of the following are valid PHP stream transports? 

  

  

  

  

UML stands for?

  

  

  

  

The session_start() function must appear..

  

  

  

  

If the directive session.cookie_lifetime is set to 3600, the cookie will live until..

  

  

  

  

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.