Quiz
Untitled
Create a free account to finish this quiz
Save your progress and see your final score.
Already have an account? Sign in
Questions in this quiz (19)
1When using the POST method, variables are displayed in the URL: (0.5 mark)
- Aa) True
- Bb) False
2What is a correct way to add a comment in PHP? (0.5 mark)
- Aa) /*…*/
- Bb) <!--…-->
- Cc) <comment>…</comment>
- Dd) *\..\*
3 Choose the correct PHP variable name(s) (1.5 marks)
- Aa) $0name
- Bb) $hello0_
- Cc) $family name
- Dd) $given_name
- Ee) $name*
- Ff) $000
- Gg) $_000
4Choose the statement that best describes the relationship between JSP and
servlets: (0.5 mark)- Aa) Servlets are built on JSP semantics and all servlets are compiled to
JSP pages for runtime usage. - Bb) JSP and servlets are unrelated technologies.
- Cc) Servlets and JSP are competing technologies for handling web requests. Servlets are being superseded by JSP, which is preferred. The two technologies are not useful in combination.
- Dd) JSPs are built on servlet semantics and all JSPs are compiled to
servlets for runtime usage.
- Aa) Servlets are built on JSP semantics and all servlets are compiled to
5What alternatives exist to embedding Java code directly within the HTML
markup of your JSP page? (0.5 mark)- Aa) Moving the code into your session manager.
- Bb) Moving the code into scriptlets.
- Cc) Moving the code into JavaBeans and servlets.
- Dd) Moving the code into a transaction manager.
6What is the output of the following code? (0.5 mark)
<% session.setAttribute("name", "John"); %>
<%= session.getAttribute("John") %>- Aa) John
- Bb) null
7 In which HTML section(s) do we insert JavaScript statements?
- Aa) The <body> section only
- Bb) Both the <head> section and the <body> section are correct
- Cc) The <head> section only
- Dd) None of the above.
8Which one of the following is the correct way to define an array in
JavaScript?- Aa) var txt = new Array("tim","kim","jim") ;
- Bb) var txt = new Array:1=("tim") 2=("kim") 3=("jim") ;
- Cc) var txt = new Array(1:"tim",2:"kim",3:"jim") ;
- Dd) var txt = new Array="tim","kim","jim" ;
9All variables in PHP start with which of the following symbols?
- Aa) &
- Bb) !
- Cc) $
- Dd) #
10 What is the correct way to include the file "time.inc" in PHP?
- Aa) <!--include file="time.inc"-->
- Bb) <% include file="time.inc" %>
- Cc) <?php include_file("time.inc"); ?>
- Dd) <?php require("time.inc"); ?>
11 What is the correct way to create a function in PHP?
- Afunction myFunction()
- Bnew_function myFunction()
- Ccreate myFunction()
- DNone of the above.
12 In PHP, in order to call a function namely foo of an object obj within the
object itself, which of the following expressions should be used?- Aa) $obj.foo()
- Bb) $obj->foo()
- Cc) both a) and b)
- Dd) $this->foo()
13 When using the GET method in HTTP protocol, form variables are displayed
in the URL:- Aa) True
- Bb) False
14Which of the following HTML elements should be used to write JavaScript?
- Aa) <js> … </js>
- Bb) <scripting> … </scripting>
- Cc) <script> … </script>
- Dd) <javascript> … </javascript>
15Select the one which is invalid in JSP.
- A<%@ include file=“hello.jsp” %>
- B<jsp:include page=“hello.jsp”></jsp:include>
- C<jsp:include page=“hello.jsp” />
- Dd) None of above
16Which of the following JSP code is correct?
- Aa) <% if (Math.random() < 0.5) { Have a good day!} %>
- Bb) Time is now: <% new Date() %>
- Cc) <% private int count = 5; %>
- Dd) None of above
17Assuming you are assigned to a student laboratory zone “abcde”,
which of following connection string can be used in FlieZilla for file uploading?- A(a) ftp://infs3202-abcde.zones.eait.uq.edu.au
- Bsftp://infs3202-abcde.uqcloud.net
- C(c) ftps:// infs3202-abcde.zones.eait.uq.edu.au
- D(d) None above
18 (1 Mark) What does DTD stand for in XML?
- A(a) Dynamic Type Definition
- B(b) Document Type Definition
- C(c) Data Type Definition
- D(d) Direct Type Definition
19(1 Mark) What is a dynamic HTML (DHTML) file?
- A(a) A dynamic HTML file is a file that is sent to client by server with script programs that will be executed on the client side to create the elements of the HTML file.
- B(b) A dynamic HTML file is a dynamic web page created by server-side scripting (such as PHP, JSP, or ASP.NET) where the web server generates content before sending it to the client.
- C(c) DHTML is similar to AJAX by the fact that a DHTML page is not to be request/reload-based.
- D(d) Both (a) and (b).
Information
- Description
- Quiz on Untitled, created by luke daniels on 17/06/2017.
- Author
- luke daniels
- Language
- English
- Views
- 4
- History
- Created on 17 Jun 2017 · updated on 17 Jun 2017
- Rating
- No ratings yet Rate this quiz