Contents
1) Features of React JS also write “Hello world” in React Js .......................................... 5
2) Explain the structure of XML Document with an example. ........................................ 6
Structure of an XML Document .......................................................................... 6
1. Prolog ........................................................................................................... 6
2. Root Element ................................................................................................ 7
3. Child Elements .............................................................................................. 7
4. Attributes ...................................................................................................... 7
5. Text Content .................................................................................................. 7
6. Comments .................................................................................................... 8
7. Processing Instructions.................................................................................. 8
Example of a Complete XML Document .............................................................. 8
3) Explain the Servlet Life cycle and Servlet Architecture with neat diagram. ................. 9
1. Loading the Servlet Class ............................................................................... 9
2. Creating a Servlet Instance............................................................................. 9
3. Calling the init() Method ........................................................................... 9
4. Calling the service() Method ................................................................... 10
5. Calling the destroy() Method ................................................................... 10
4) Draw a diagram of Ajax application model and Traditional application web model and
compare them. ...................................................................................................... 13
5) Explain how Shadow effect can be applied on Text using CSS with suitable example 14
6) Write a note on JSP.............................................................................................. 15
7) What is mean by Event handling in JavaScript explain it with example..................... 16
8) Write a short note on JDBC. ................................................................................ 18
9) Explain the working of rowspan and colspan of table when used in HTML with suitable
example. ............................................................................................................... 19
10) What is AJAX? Explain its role in web application. ................................................ 21
11) Discuss about various control structures used in PHP. Give suitable example for
each. .................................................................................................................... 22
12) What is HTTP? Describe structure of HTTP request and response Message. .......... 25
13) Explain CSS3 Animation with example................................................................ 26
14) Explain life cycle of JSP. ..................................................................................... 27
1
15) Write a JavaScript that reads ten numbers and displays the count of negative
numbers, the count of positive numbers and the count of zero from the list. .............. 28
16) Explain any 5 semantic tags of HTML5 with example............................................ 29
17) What is JSX? Explain its attributes with example. ................................................. 30
18) Explain Exception handling in Javascript with suitable example. ........................... 31
19) Write a JSP Program to perform four basic arithmetic operations,
Addition,Subtraction, Division and Multiplication. .................................................... 32
20)An e-commerce website would like to accept the below mentioned data and ........ 34
would like to transfer the data using XML, ................................................................ 34
Product ID ............................................................................................................. 34
Product Name ....................................................................................................... 34
Product Cost ......................................................................................................... 34
Purchase Date ....................................................................................................... 34
Purchased by ......................................................................................................... 34
Seller Name........................................................................................................... 34
Write the HTML, XML code and DTD for the given data. ............................................. 34
21) Differentiate between HTML and HTML5 ............................................................. 36
22) What is inheritance in CSS? Explain CSS Animation properties. ........................... 37
23) Explain and elements in HTMLS with example. .................................................... 38
24) What is the diff between the class selector and ID selector. ................................. 40
25) Write an external style sheet and link it with HTML code. The stylesheet should
include the following .............................................................................................. 40
a.) The web page will have the background image "img.jpg". ...................................... 40
b.) The table headings will have red background color. .............................................. 40
c.) Background colour of alternate paragraphs are different. ..................................... 40
d.) The hyperlinks on the web page will not have underline. ....................................... 40
26) Write HTML code to process online Alumni information for your college. Create
forms to get name, address, date of birth, and email id. Write JavaScript code to validate
the following .......................................................................................................... 42
a.) User has filled all the fields prior to form submission ........................................... 42
b.) Valid email id (with ‘@' and ‘.’ ) ............................................................................. 42
c.) Age validation using DOB (>=22 years) ................................................................ 42
27) Write a code to Drag an image from outside the box and Drop it inside the box ...... 43
2
28) Create an external Stylesheet and link it to an HTML form, the stylesheet should
contain the following, ............................................................................................. 44
a.) An header in text with Red Text Colour and Yellow background colour ................... 44
b.) A Double lined (Border) table .............................................................................. 44
c.) The table should have 5 Rows and 3 Columns ..................................................... 44
d.) In the First column Sr. No. of the product, Second Column Image with hyperlink and
Name of the Product, and Third Column the description of the product ..................... 44
29) Create a form which has the following fields 'Name', 'Age', 'Email ID’, "Password'.
Using Javascript validate each field as follows. ......................................................... 46
a.) Name should be between A-Z ............................................................................. 46
b.) Age should be between 0-100 ............................................................................. 46
c.) Email ID should contain ‘@‘ ................................................................................ 46
d.) Password should contain 1 Upper case, 1 Digit, 1 Special character and length
should be minimum 8 ............................................................................................. 46
30) List and Explain the 3 ways to add style sheet (CSS) to an HTML web page with
suitable example ................................................................................................... 48
31) What are benefits of using JSON over XML. ......................................................... 49
32) Write a JavaScript to check password and confirm password are same or not. ...... 50
33) Explain Document Object Model in detail. .......................................................... 51
34) Explain Built - in object in javascript ................................................................... 52
35) Explain how JavaScript can hide HTML Elements with suitable example. .............. 53
36) Diff. Between JSON and XML. ............................................................................ 54
37) What is Session in Servlet? ................................................................................ 54
List and Explain Session Tracking Techniques(List different way to handle it). ............. 54
38) Explain the steps to connect Java Application to Database using JDBC. ................ 55
39) What are cookies? And how do cookies work in servlets? .................................... 56
40) Give Characteristics of RIA ................................................................................ 56
41) Explain the features of PHP and Write a PHP Program to print Factorial of number 57
42) How to define the variable in PHP and also explain the scope of variable. ............. 57
43) Write a program in JSP to display system date and time. ...................................... 59
44) Create a well formed XML document to maintain Library catalogue. It should contain
the name of the book, author, publisher and year of publishing, format it in tabular
manner using XSLT. ................................................................................................ 59
3
45) If you wanted to send sensitive information like password to the backend which
among the GET and the POST method in PHP would you use, justify your answer and
distinguish between these methods. ....................................................................... 61
46) Explain how form validation works in PHP, with a suitable example ...................... 61
47) What is DTD? Explain internal DTD and external DTD. .......................................... 63
48) Explain the different datatypes of PHP. ............................................................... 63
1. String ........................................................................................................ 63
2. Integer ..................................................................................................... 64
3. Float ......................................................................................................... 64
4. Boolean ................................................................................................... 64
5. Array ........................................................................................................ 65
6. NULL .......................................................................................................... 65
49) Discuss the advantages of React Js. ................................................................... 65