Web Technologies Fundamentals

A quiz covering fundamental web technologies including JavaScript, HTML, Java Servlets, JSP, and PHP scripting

18 Questions Published

Questions

Question 1 Multiple Choice (Single Answer)
  1.  A script is a
    
  1. Program or sequence of instructions that is interpreted or carried out by processor directly
  2. Program or sequence of instruction that is interpreted or carried out by another program
  3. Program or sequence of instruction that is interpreted or carried out by web server only
  4. None of above
Question 2 Multiple Choice (Single Answer)
  1.  When compared to the compiled program, scripts run
    
  1. Faster
  2. Slower
  3. The execution speed is similar
  4. All of above
Question 3 Multiple Choice (Single Answer)
  1. PHP is a widely used ……………. scripting language that is especially suited for web development and can be embedded into html
  1. Open source general purpose
  2. Proprietary general purpose
  3. Open source special purpose
  4. Proprietary special purpose
Question 4 Multiple Choice (Single Answer)
  1.  Which of the following is not true?
    
  1. PHP can be used to develop web applications
  2. PHP makes a website dynamic.
  3. PHP applications can not be compiled.
  4. PHP can not be embedded into html.
Question 5 Multiple Choice (Single Answer)
  1.  The most portable version of PHP tag that is compatible to embed in XML or XHTML too is:
    
  1. <? ?>
  2. <script language=”php”> </script>
  3. <% %>
  4. <?php ?>
Question 6 Multiple Choice (Single Answer)
  1.  Which of the following variables is not a predefined variable?
    
  1. $get
  2. $ask
  3. $request
  4. $post
Question 7 Multiple Choice (Single Answer)
  1.  You can define a constant by using the define() function. Once a constant is defined
    
  1. It can never be changed or undefined
  2. It can never be changed but can be undefined
  3. It can be changed but can not be undefined
  4. It can be changed and can be undefined
Question 8 Multiple Choice (Single Answer)
  1.  The following piece of script will output:  <?  $email=’[email protected]’;  $new=strstr($email, ‘@&rsquo;  print $new;  ?>
    
  1. admin
  2. admin@psexam
  3. @psexam.com
  4. psexam.com
Question 9 Multiple Choice (Single Answer)
  1. Which of the following function returns the number of characters in a string variable?
  1. count($variable)
  2. len($variable)
  3. strcount($variable)
  4. strlen($variable)
Question 10 Multiple Choice (Single Answer)
  1. When you need to obtain the ASCII value of a character which of the following function you apply in PHP?
  1. chr( );
  2. asc( );
  3. ord( );
  4. val( );
Question 11 Multiple Choice (Multiple Answers)

Which are the JSP scripting elements below?

  1. Declarations
  2. Scriptlets
  3. Expressions
  4. Include
Question 12 Multiple Choice (Single Answer)

How many JSP scripting elements are there?

  1. 5
  2. 3
  3. 4
  4. 2
Question 13 Multiple Choice (Single Answer)

Fullform of a JSP ?

  1. Java servlet paper
  2. Java server Paper
  3. Java Server Pages
  4. None
Question 14 Multiple Choice (Multiple Answers)

What are the common mechanisms used for session tracking?

  1. Cookies
  2. URL- rewriting
  3. sessions
  4. SSL sessions
Question 15 Multiple Choice (Multiple Answers)

Explain the life cycle methods of a Servlet?

  1. init(ServletConfig config)
  2. service( ServletRequest req, ServletResponse res)
  3. destroy( ServletRequest req, ServletResponse res)
  4. destroy()
Question 16 True/False

A doGet() method is limited with 2k of data to be sent?

  1. True
  2. False
Question 17 Multiple Choice (Single Answer)

Inside which HTML element do we put the JavaScript?

  1. <js>
  2. <javascript>
  3. <script>
  4. <scripting>
Question 18 Multiple Choice (Single Answer)

What is the correct JavaScript syntax to write "Hello World"?

  1. "Hello World"
  2. document.write("Hello World")
  3. response.write("Hello World")
  4. ("Hello World")