Web Technology: Comprehensive Viva Questions Total Questions in this document: 70 Html 1. Who is making the Web standards? a) The World Wide Web Consortium b) Mozilla c) Microsoft d) Distributed Management Task Force Inc. Answer: a 2. What is the correct HTML for creating a hyperlink? a) <a url="http://www.w3schools.com">W3Schools.com</a> b) <a href="http://www.w3schools.com">W3Schools</a> c) <a name="http://www.w3schools.com">W3Schools.com</a> d) <a>http://www.w3schools.com</a> Answer: b 3. How can you create an e-mail link? a) <a href="mailto:xxx@yyy"> b) <mail href="xxx@yyy"> c) <a href="xxx@yyy"> d) <mail>xxx@yyy</mail> Answer: b 5. How can you open a link in a new browser window? a) <a href="url" target="_blank"> b) <a href="url" target="new"> c) <a href="url" new> d) <a href=”url” new window> Answer: a 6. What is the correct HTML for making a drop-down list? a) <dl> b) <list> c) <ul> d) <ol> Answer: c 7. What is the correct HTML for inserting an image? a) <img href="image.gif" alt="MyImage" /> b) <img alt="MyImage">image.gif</img> c) <image src="image.gif" alt="MyImage" /> d) <img src="image.gif" alt="MyImage" /> Correct Answer: d 9. What is the correct HTML for inserting a background image? a) <img src="background.gif" background /> b) <img image= “background.gif” background> c) <body background="background.gif"> d) <background img="background.gif"> Answer: c 9. Which of these tags are all <table> tags? a) <table><head><tfoot> b) <table><tr><td> c) <thead><body><tr> d) <table><tr><tt> Answer: b 10. Hypertext Transfer Protocol Secure (HTTPS) is a combination of ________________________ Protocol with _______________ protocol. Answer: Hypertext Transfer Protocol (HTTP) with SSL/TLS protocol. 11. Which statement is true for session tracking. a) URL Rewriting. b) Hidden from fields. c) Cookies. d) Using Secure Sockets Layer. e) All of the above. Answer: e JavaScript 1. _____ JavaScript statements embedded in an HTML page can respond to user events such as mouse-clicks, form input, and page navigation. A. Client-side B. Server-side C. Local D. Native Answer: A 2. Which of the following can't be done with client-side JavaScript? A. Validating a form B. Sending a form's contents by email C. Storing the form's contents to a database file on the server D. None of the above Answer: C 3. Which is the correct way to write a JavaScript array? A. var txt = new Array(1:"tim",2:"kim",3:"jim") B. var txt = new Array:1=("tim")2=("kim")3=("jim") C. var txt = new Array("tim","kim","jim") D. var txt = new Array="tim","kim","jim" Answer: C 4. Which of the following is not considered a JavaScript operator? Correct Answer: B A. new B. this C. delete D. typeof Answer: b 5. Actions that can be detected by javascript are called ? a) HTML b) Events c) Array Answer: b 6. How to create a Date object in JavaScript? A. dateObjectName = new Date([parameters]) B. dateObjectName.new Date([parameters]) C. dateObjectName := new Date([parameters]) D. dateObjectName Date([parameters]) Answer: A 7. To set up the window to capture all Click events, we use which of the following statement? A. window.captureEvents(Event.CLICK); B. window.handleEvents (Event.CLICK); C. window.routeEvents(Event.CLICK ); D. window.raiseEvents(Event.CLICK ); Answer: A; 8. _______ class provides an interface for invoking JavaScript methods and examining JavaScript properties. Answer: JSObject 9. To open a dialog box each time an error occurs, which of the following is added to prefs.js? A. user_pref("javascript.classic.error_alerts", true); B. user_pref("javascript.classic.error_alerts ", false); C. user_pref("javascript.console.open_on_error ", true); D. user_pref("javascript.console.open_on_error ", false); Answer: A 10. The syntax of capture events method for document object is ______________ Answer: C A. captureEvents() B. captureEvents(args eventType) C. captureEvents(eventType) D. captureEvents(eventVal) Correct Answer: C / captureEvents(eventType) CSS 1. What is the correct HTML for referring to an external style sheet? a) <stylesheet>mystyle.css</stylesheet /> b) <link rel="stylesheet" type="text/css" href="mystyle.css"> c) <style src="mystyle.css" /> Answer: b Correct Answr: b / <link rel="stylesheet" type="text/css" href="mystyle.css"> 2. Which HTML tag is used to define an internal style sheet? a) <style> b) <script> c) <css> Answer: a 3. Which is the correct CSS syntax? a) {body:color=black(body} b) body {color: black} c) {body;color:black} d) body:color=black Answer: b XML 1. Which statement is NOT True. a) XML stands for EXtensible Markup Language b) XML was designed to carry data, not to display data c) XML was designed to display data, not to carry data. d) XML tags are not predefined. You must define your own tags. e) None of the above. Answer: c 2. Which statement is NOT True. a) All XML Elements must have a closing tag. b) XML tags are case sensitive. c) XML elements must be properly nested. d) Xml documents have a root element. e) None of the above. Answer: e 3. What does XML stand for? a) eXtra Modern Link b) eXtensible Markup Language c) X-Markup Language d) Example Markup Language Answer: b 4. There is a way of describing XML data, how? a) XML uses a description node to describe data b) XML uses a DTD to describe the data c) XML uses XSL to describe data Answer: a 5. What is the correct syntax of the declaration which defines the XML version? a) <?xml version="1.0" /> b) <?xml version="1.0"?> c) <xml version="1.0" /> Answer: a 6. What does DTD stand for? a) Document Type Definition b) Dynamic Type Definition c) Direct Type Definition d) Do The Dance Answer: a 7. What does XSL stand for? a) eXtensible Style Listing b) eXtra Style Language c) eXpandable Style Language d) eXtensible Stylesheet Language Answer: d 8. What is a correct way of referring to a stylesheet called "mystyle.xsl" ? a) <link type="text/xsl" href="mystyle.xsl" /> b) <stylesheet type="text/xsl" href="mystyle.xsl" /> c) <?xml-stylesheet type="text/xsl" href="mystyle.xsl" ?> Answer: a 9. For the XML parser to ignore a certain section of your XML document, which syntax is correct? a) <CDATA> Text to be ignored </CDATA> b) <PCDATA> Text to be ignored </PCDATA> c) <![CDATA[ Text to be ignored ]]> d) <xml:CDATA[ Text to be ignored ]> Answer: c Servlets 1) Which statement is true? a) Both Generic Servlet and HttpServlet implements Serializable Interface. b) Both these classes are abstract. c) GenericServlet defines a generic,protoco-independent servlet. d) All statements are true. Answer: d 2) For getting locale-specific object, it needs to load _____________ class. Answer: ResourceBundle 3) For a web application development strcture, in which directory contains web.xml file in web application development strcture. a) classes b) lib c) webapps d) web-inf Answer: d 4) For a web application development structure, in which directory contains servlet class files. a) classes b) lib c) webapps d) servlet. Answer: a 5) Which attribute or xml tag is not valid in web.xml a) init-servlet b) servlet-mapping c) url-pattern d) servlet-name Answer: a 6) JSTL stands for 1) Java Server Transcation Language 2) JSP Standard Tag Library 3) Java Server Tag Library 4) None of the above. Answer: 2 7) A java framework that allows us to access database through java program is called ____________ Answer: jdbc 8) Which Package contains the JDBC API? a) java.jdbc.* b) javax.jdbc.*; c) java.sql.*; d) javax.sql.*; Answer:c 9) We send and receive HTML files files using which protocol? a) SMTP b) POP3 c)HTTP d) FTP Answer: c 10) Which driver is called Pure Java Driver? a) 1 b) 2 c) 3 d) 4 Answer: d 11) In Tomcat Server, ____________ jar file is required to compile servlets. Answer: servlet-api.jar 12) ____________ is Tomcat's servlet Container. Answer: Catalina 13) ___________ object is used to encapsulates the retrieved data for executeQuery() method of Statement. Answer: java.sql.ResultSet 14) ______________ class is used to open a connection to a given database. Answer: DriverManager 15) ________________ is the process of writing the state of an object to a byte stream. Answer: Serialization. 16) _______________method of class HttpServletRequest used to get an array of of all the cookies. Answer: getCookies(); 17) SMTP stands for _________________________________ Answer: Simple Mail Transfer Protocol. JSP 1) Which of the following statement is true? a) It has public no arguments contructor. b) It has setter and getter methods for its properties. c) If required it must be serializable. d) All statements are true. Answer: d 2) Which one of them is not implicit object in JSP? a) javabean b) request c) pageContext d) none of the above. Answer: javabean 3) JSP Syntax for comment is (a) <!- -> (b) <% %> (c) <%= %> (e) none of the above Answer: a 4) How many JSP Scripting elements are there? a) 1 b) 2 c) 3 d) 4 5) Structs is an a) Factory Design Pattern Implementation b) Bridge Design Pattern Implementation c) Singleton Design Pattern Implementation d) MVC Design Pattern Implementation Answer: d 6) Controller in MVC Design Pattern a) Represents for intercepting the requests from view and passes it to model for the appropriate action. b) Represents the presentations of the application. c) Represents enterprise data and business rules. d) None of the above. Answer: a 7) Which jar file contains JSTL API Classes? a) servlet-api.jar b) jsp-api.jar c) standar.jar d) None of the above. 8) JSP Technology separates ___________________ Answer: presentation and business logic 9) ____________ is Tomcat's JSP Engine. Answer: Jasper 10) In order to be persistent, a Java Bean needs to implement the ______________ interface. Answer: java.io.Serializable interface. 11. WAR stands for ____________________________ Answer: Web Application Archive 12. TLD stands for ____________________________ Answer: Tag Library Descriptor 13. ______________________ file is the application deployment descriptor that contains all configuration information for the application. Answer: web.xml 14. _______________________ element maps a servlet or JSP page to a URL pattern. Answer: <Servlet-mapping> 15. Which one of the element embeds most elements dealing JSP configuration in web.xml. a) <servlet-mapping> b) <session-config> c) <security-constraint> d) <jsp-config> Answer: d 16. ________________ is the command to create WAR file. Answer: jar cvf <filename.war> * 17. _________________ tag is used to declare the java bean in JSP page. Answer: <jsp:useBean> 18. Which one of the below tag library is used to handle Internalization and Locales. a) <%@ taglib prefix=”fmt” uri=http://java.sun.com/jsp/jstl/fmt %> b) <%@ taglib prefix=”sql” uri = http://java.sun.com/jsp/jstl/sql %> c) <%@ taglib prefix=”fn” uri=http://java.sun.com/jsp/jstl/functions %> d) <%@ taglib prefix=”c” uri = “http://java.sun.com/jsp/jstl/core %> Answer: a 18. Which one of the below is directive element. a) <jsp: useBean> b) <%@ include ….%> c) <! ……… %> d) <!@ …….%>. Answer: b 19. JSP comment looks like a) /* ……….. */ b) <%@ ….. %> c) <%! …….. %> d) <%-- ….. %> Answer: d 20. which statement is not true about Javabeans. a) JavaBeans are not reusable software components for Java. b) They contain setter and getter methods. c) Javabean class implements Serializable Interface. d) JavaBeans are reusable software components for Java. e) None of the above. f) All the above. Answer: f ---------------------------------------END OF THE DOCUMENT -------------------------- ddd
Aware Center, Bhagawatipuram, Maheswaram Cross Roads, R R District, 501359, Telangana.
welcome
welcome to our college social blog
we have lot of information about our college fest and events etc
all of our college members join in this site .
to add to this blog
click on follow then select google
after that log in with your gmail id
thank you
KARTHIK REDDY.
Thursday, March 22, 2012
Web Technology
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment