T.Y.B.B.A.(C.A.) Sem-V Practical Examination Lab Course- I (Web Technology) Solved Slips

 

Class:-T.Y.B.C.A                                                           Practical No:-

 

Q)Write HTML and CSS code to design a web page.Divide the browser screen into two frames.The first frame will display the headings.Divide the second frame into two columns.

    The frame on the right contains a image of “Home and

 Kitchen Appliances”.The frame on the left contains a menu consisting Of  hyperlinks.

    Clicking on any one of these hyperlinks will display related

information in a new page.

    Use External Style Sheet with appropriate attributes to

 display information of each frame.

Answer:-

 

a.html

<html>

<head>

<title> Welcome </title>

<link href="format.css" rel="stylesheet">

</head>

<body>

<b><p>Home Shopping </p></b>

</body>

</html>

 

img.html

<html>

<head>

<title> Image</title>

<link href="format.css" rel="stylesheet">

</head>

<body>

<img src="Desert.jpg" width="120" height="320">

</body>

</html>

k.html

<html>

<head>

<link href="forrmat.css" rel="stylesheet">

</head>

<body>

<h3> Kitchen & dining </h3>

<ol type="i">

<li> Cookware

<li>Bakeware

<li>Serveware

</ol>

</body>

</html>

f.htm

<html>

<head>

<link href="forrmat.css" rel="stylesheet">

</head>

<body>

<h3> Furnishing </h3>

<ol type="i">

<li> Sofa

<li>wardrobe

<li>Bed

</ol>

</body>

</html>

 

main.html

<html>                                                                                                

<frameset rows="15%,85%">

<frame src="a.html">

<frameset cols="25%,75%">

<frame src="img.html">

<frame src="welcome.html">

</frameset>                                                                                                   

</frameset>

</html>

 

Welcome.html

<html>

<head>

<title> Welcome</title>

<link href="format.css" rel="stylesheet">

</head>

<body>

<h3>Home & kitchen appliances </h3>

<ul type="square">

<li><a href="k.html" target=blank> kitchen &  dining </a></li>

<li><a href="f.html" target=blank> Furnishing </a></li>

<li><a href="h.html" target=blank> Home Decor</a></li>

<li><a href="i.html" target=blank> Home Improvement </a></li>

</ul>

</body>

</html>

Output:-

 

 

 

 

 

 

 

 

Class:-T.Y.B.C.A                                                           Practical No:-

 

Q)Write HTML and CSS code to design a web page displaying list

of hyperlinks.  Divide the browser screen into two frames.The first frame will

display the heading.  Divide the second frame into two columns.The frame on the left will

be a menu consisting  of hyperlinks.Clicking on any one of these hyperlinks will display

 related information as a  new page which must be open in frame on the right hand side.

    Use Inline Style Sheet with appropriate attributes to display information of each frame.

 

  Answer:-

 

main.html

 

<html>

<frameset rows="20% ,80%">

<frame src="top.html">

<frameset cols="30%,70%">

<frame src="left.html" name="1">

<frame name="2">

</frameset>

</frameset>

</html>

 

 

Top.html

 

<html>

<body>

<center><h1 style="font-size:48pt;font-family:arial;color:blue">

IT Industries in India </h1></center>

</body>

</html>

 

 

left.html

 

<html>

<body>

<center><h1 style="font-size;48pt;font-family:arial;color:blue">

city</h1></center>

<ol type="1">

<li><a href="pune.html" target="2"> Pune </a></li></br>

<li><a href="banglore.html" target="2"> Banglore </a></li></br>

<li><a href="hydra.html" target="2"> Hydrabad </a></li></br>

<li><a href="delhi.html" target="2"> Delhi </a></li></br>

</ol>

</body>

</html>

 

 

Pune.html

 

<html>

<body>

<h2 style="font-size:48pt;font-family:arial;color:blue"> PUNE </h2>

<ul>

<li>Wipro

<li>TCS

<li>ATOS

<li> KPIT

</body>

</html>

 

 

hydra.html

 

<html>

<body>

<h2 style="font-size:48pt;font-family:arial;color:blue"> Hydrabad </h2>

<ul>

<li>Infosys

<li>TCS

<li>Tech Mahindra

<li> Capgemini

</body>

</html>

 

 

banglore.html

 

<html>

<body>

<h2 style="font-size:48pt;font-family:arial;color:blue"> Banglore </h2>

<ul>

<li>Infosys

<li>TCS

<li>Tech Mahindra

<li> Capgemini

</body>

</html>

 

 

Output:-

 

 

 

 

 

 

 

 

Class:-T.Y.B.C.A                                                           Practical No:-

 

Q) Write a Javascript Program to read a number from user,Store

its factors its factors into the array

     and display that array.(Handle onClick Event)

 

Answer:-

 

 

factor.html

 

<html>

<head>

<script language="Javascript">

function cal()

{

var num=parseInt(document.f1.t1.value);

var fact=new Array();

var i=0,j;

for(j=1;j<=num;j++)

{

if(num%j==0)

{

fact[i]=j;

i++;

}

}

document.writeln("Factor of number are" +fact.join());

}

</script>

</head>

 

<body>

<form name="f1">

Enter Number:<input type="text" name=t1><br>

<input type="button" value="CLICK" onClick="cal()">

</form>

</body>

</html>

Output:-

 

 

 

 

 

 

 

 

 

 

 

Class:-T.Y.B.C.A                                                           Practical No:-

 

Q) Write HTML and  CSS code to design a web page.Divide the browser screen into two frames.

     The first frame will display the heading.The second frame contains a menu consisting a hyperlinks.

     Clicking on any one of these hyperlinks will display related information in a new page as shown below.

 

    Answer-:

 

Slip5.html

 

<html>

<frameset cols="50%,50%">

<frame src="head.html" name="left">

<frame src="menu.html" name="right">

</frameset>

</html>

 

head.html

 

<html>

<head>

<style type="text/css">

body{background:ligtgrey}

h1{font-family:serif,font-size:32pt;color:black;text-align:center}

</style>

</head>

<h1> Computer Application Department </h1>

</body>

</html>

 

 

 

menu.html

 

<html>

<head>

<style type="text/css">

body{ background:lightgrey}

h2{font-family:serif;font-size:30pt;color:blue;text-align:center}

</style>

</head>

<body>

<h2> Lecture Time Table </h2>

<a href="fy.html" target="_blank"> F.Y.B.C.A </a><br>

<a href="sy.html" target="_blank"> S.Y.B.C.A </a><br>

<a href="ty.html" target="_blank"> T.Y.B.C.A </a><br>

</body>

</html>

 

 

fy.html

 

<html>

<head>

<style type="text/css">

body{background:lightgrey}

h2{font-family:serif;font-size:30pt;color:blue;text-align:center}

</style>

<head>

<body>

<h2> FYBCA Time Table </h2>

<table border="2" align=center>

<tr>

<th> Time        </th>

<th> Monday   </th>

<th> Tuesday   </th>

<th> Wednesday         </th>

<th> Thursday </th>

<th> Friday      </th>

<th> Saturday  </th>

</tr>

<tr>

<td> 8.40-9.30 </td>

<td>M.O.S       </td>

<td>Accounting           </td>

<td> B.C          </td>

<td> O.B          </td>

<td> E-Comm </td>

</tr>

</table>

</body>

</html>

 

 

sy.html

 

<html>

<head>

<style type="text/css">

body{background:lightgrey}

h2{font-family:serif;font-size:30pt;color:blue;text-align:center}

</style>

 

<head>

<body>

<h2> SYBCA Time Table </h2>

<table border="2" align=center>

<tr>

<th> Time </th>

<th> Monday   </th>

<th> Tuesday   </th>

<th> Wednesday         </th>

<th> Thursday </th>

<th> Friday      </th>

<th> Saturday  </th>

</tr>

<tr>

<td> 8.40-9.30             </td>

<td> Rdbms     </td>

<td> DS            </td>

<td> O.S          </td>

<td> B.M         </td>

<td> S.E           </td>

</tr>

</table>

</body>

</html>

 

 

ty.html

 

<html>

<head>

<style type="text/css">

body{background:lightgrey}

h2{font-family:serif;font-size:30pt;color:blue;text-align:center}

</style>

<head>

<body>

<h2> TYBCA Time Table </h2>

<table border="2" align=center>

<tr>

<th> Time        </th>

<th> Monday   </th>

<th> Tuesday   </th>

<th> Wednesday         </th>

<th> Thursday </th>

<th> Friday      </th>

<th> Saturday  </th>

</tr>

<tr>

<td> 8.40-9.30             </td>

<td> Web Tech            </td>

<td> Java         </td>

<td> Dot Net   </td>

<td> OOSE       </td>

<td> Project    </td>

</tr>

</table>

</body>

</html>

 

 

 

 

 

 

 

 

Output:-

 

 

 

 

 

 

 

 

 

 

 

Class:-T.Y.B.C.A                                                           Practical No:-

 

 Q) Write a Javascript program to read a characters string from

 user and perform the following functions:

a.        Accept a character from user and count the number of

occurrences of that character in the string.

b.        Accept a position from user and print the character at

specified position.

            (Use Prompt() function for accepting a character)

 

Answer:-

 

 

noofoccur.html

 

<html>

<head>

<script language ="Javascript">

function cal()

{

var ch=document.f1.r1.value;

var str=document.f1.t1.value;

 

if(ch=="count")

{

var c=prompt("Enter characters");

var cnt=0;

var i;

for(i=1;i<str.length;i++)

{

if(str[i]==c)

{

cnt++;

}

}

alert("Number of occurence of character is" +cnt);

}

 

if(ch=="print")

{

var pos=parseInt(prompt("Enter the position"));

var ans=str.charAt(pos-1);

document.write("character at position" +pos+ "is" +ans);

}

}

</script>

</head>

 

 

<body>

<form name="f1" method="get">

Enter the string-:<input type="text" name="t1"><br>

<input type="radio" name="r1" value="count">

Accept the character from user and count its occurences<br>

<input type="radio" name="r1" value="print">

Print character at particular position <br>

<input type="button" value="SUBMIT" onclick="cal()">

 

</form>

</body>

</html>

 

 

 

Output:-

 

 

 

 

 

 

 

 

 

 

 

 

Class:-T.Y.B.C.A                                                           Practical No:-

 

Q)Write HTML code to design a website of facebook. Design three pages Home, Profile and Find Friends Request page which are linked to each other. Design First two pages of website (Home &Profile ) as shown below. And Third page (Find Friends Request) contains information as Image ,Name of Sender ,And two buttons Confirm and Delete.

Welcome to Ivan Bayross

Logout

Home

Profile

Find Friends

Raj shared this link

Image

Like

Share

Comment

Profile Page

Home

Ivan Bayross

Comment / Message

Timeline

About

Friends

Photo

Post

 

 

 

 

 

 


Code:-

 

Slip9.html

<html>

<frameset rows="20%,*">

<frame src="welcome.html" name="top">

<frameset cols="30%,*">

<frame src="menu.html" name=left>

<frame src="home.html" name="right">

</frameset>

</frameset>

</html>

 

Profile.html

 

<html>

<body>

<h2><a href="home.html" align="left">Home</a></h2><br>

<h2> Profile Page</h2>

<img src="Tulips.jpg" height="70%" width="70%">

<h3> Ivan Bayross</h3>

<textarea rows=5 cols=10> Comment/Message</textarea>Post<br>

<a href=t.html>Timeline</a>&nbsp;&nbsp;&nbsp;

<a href=a.html>About</a>&nbsp;&nbsp;&nbsp;

<a href=friend.html target="_blank">Friends</a>

</body>

</html>

 

 

Welcome.html

<html>

<body>

<h1 align="center"> Welcome to Ivan Bayross</h1>

</body>

</html>

 

 

Menu.html

<html>

<body>

<a href="home.html" target="right">home</a>

<br>

<a href="profile.html" target="right">profile</a>

<br>

</body>

</html>

 

 

home.html

 

<html>

<body>

<h2> Raj shared this link</h2>

<img src="tulips.jpg" height="50" width="50">

<form>

<input type="button" value="like">&nbsp;&nbsp;

<input type="button" value="Share">&nbsp;&nbsp;

<input type="button" value="Comment">

</form>

</body>

</html>

friend.html

 

<html>

<body>

<h2>Find friend request</h2>

<img src="tulips.jpg" height=70 width=70><br>

<h3>Name of sender:Sujit</h3>

<form>

<input type="button" value="Confirm">&nbsp;&nbsp;

<input type="button" value="Delete">

</form>

</body>

</html>

 

Output:-

 

 

 

 

 

 

 

 

 

 

           

Class:-T.Y.B.C.A                                                           Practical No:-

 

Q)Write a JavaScript program to design student registration form and perform following validation:

- Check all fields should not contain a null value

- Check name field contains only alphabets

- Mobile No. field should be of 10 digits.s

- Pin code field should be of 06 digits.

Answer:-

 

 

Studreg.html

 

<html>

<head>

<script language="javascript">

function valid()

{

var nm=document.f1.name.value;

var mob=document.f1.mobile.value;

var add=document.f1.address.value;

var ct=document.f1.city.value;

var st=document.f1.State.value;

var pin=document.f1.pincode.value;

if((nm==" ") || (mob==" ") || (add==" ") || (ct==" ") || (st==" ") || (pin==" "))

{

alert("Enter the data for all the field");

}

if(!isNaN(nm))

{

alert("Name Should not contain Number");

}

if(mob.length!=10)

{

alert("Moblie number should contain 10 digit");

}

if(pin.length!=6)

{

alert("Pin Code should contain 6 digit");

}

}

</script>

</head>

<body>

<h1 align="center">Student Registration Form</h1>

<form name="f1">

Name of Student: <input type="text" name="name"><br>

Mobile No.: <Input type="text" name="mobile"><br>

Address Line: <Input type="text" name="address"><br>

City: <Input type="text" name="city"><br>

State: <Input type="text" name="State"><br>

Pincode: <Input type="text" name="pincode"><br>

<input type=button value=SUBMIT onClick="valid()">

<input type=reset value=RESET>

</body>

</html>

 

Output:-

 

 

 

Post a Comment

0 Comments