0% found this document useful (0 votes)
256 views26 pages

Sycs Web Technology Practical Manual Semester - Iii

WEB TECHNOLOGIES PRACTICALS

Uploaded by

Nikhil Hadawale
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
256 views26 pages

Sycs Web Technology Practical Manual Semester - Iii

WEB TECHNOLOGIES PRACTICALS

Uploaded by

Nikhil Hadawale
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 26

INDEX

Sr No Topic Date Sign


1. Practical No :- 1
a) Aim :- Design A Webpage That Makes Use Of Document
Structure Tags. 06/07/2024
b) Aim :- Various Text Formatting Tags
c) Aim :- List Tags.
2. Practical No :- 2
a) Aim :- Design A Webpage That Makes Use Of Table.
b) Aim :- Form Tags (forms with various elements) 11/07/2024
c) Aim :- Navigation Across Multiple Pages.
3. Practical No :- 3
a) Aim :- CSS Properties To Design Websites Using CSS
(Cascading Style Sheets). 16/07/2024
b) Aim :- CSS Properties To Change Fonts And Styles.

4. Practical No :- 4
a) To Calculate Factorial Of A Given Number. 23/07/2024
b) To Calculate The Fibonacci Series Up To n Terms.
5. Practical No :- 5
a) Aim :- To Work With The Strings In Html And Javascript.
b) Aim :- To Work With Date & Time In Html And 30/07/2024
Javascript.
6. Practical No :- 6
Aim :- Write A PHP Script For Retrieving Data From HTML 10/09/2024
Forms.
7. Practical No :- 7
a) Aim:- Write A PHP And HTML Script To Design
Registration Form And Retrieve Data From.
b) Aim :- Write A PHP Script For Performing Certain
Mathematical Operations Such As Calculating Factorial.
c) Aim :- Write A PHP Script To Print Fibonacci Series up to
10 Terms 10/09/2024
d) Aim :- Write A HTML And PHP Script To Input Lower
Bound & Upper Bound & Print All The Prime Number
Between Lower Bound and Upper Bound.
e) Aim :- Write A PHP Script For Performing Certain
Mathematical Operations To Calculate Reverse Of A
Number.
8 Practical No :- 8
Aim :- Write PHP Script For Storing and Retrieving Cookies. 10/09/2024
PRACTICAL NO 1 :-
a) Aim :- Design A Webpage That Makes Use Of Document Structure Tags.
Source Code :-
<html>
<head>
<title> Practical Number :- 1(A) Use Of Structure Document Tag
</title>
</head>
<body>
<div>
<h3> Design A Webpage That Makes Use Of Document Structure
Tags. </h3>
<p> This is a Paragraph......</p>
</div>
</body>
</html>

Output :-
b) Aim :- Various Text Formatting Tags.
Source Code :-
<html>
<head>
<title> Practical No:- 1(B) </title>
</head>
<h1> Practical No :- 1(B) </h1>
<p> <b> CGT </b>
</p>
<p> <I> WEB TECHNOLOGY </I></p>
<p> <u> CORE JAVA </u></p>
<p> X<sup> 2 </sup></p>
<h2> Log<sub> e </sub></h2>
<h2><strike> DATABASE MANAGEMENT SYSTEM </strike></h2>
</body>
</html>

Output :-
c) Aim :- List Tags.
Source Code :-
<html>
<head>
<title> Practical No :- 1(C) LIST TAG EXAMPLES</title>
</head>
<body>
<h1> TYPE OF LIST TAG </h1>
<h3> ORDER LIST </h3>
<ol type="1">
<li> C Programming </li>
<li> Object Oriented Using C++ </li>
<li> Linux </li>
</ol>
<h3> UNORDER LIST </h3>
<ul type="disc">
<li> Web Technologies </li>
<li> Advance Database System </li>
<li> Java </li>
<li> Operating System </li>
</ul>
<dl>
</dt>
<dt> FRUITS </dt>
<dt> APPLE <br> MANGO </dt>
<dt> COLORS </dt>
<dt> BLUE <br> GREEN </dt>
<dt> SPORTS </dt>
<dt> HOCKEY <br> CRICKET </dt>
</dl>
</body>
</html>

Output :-
PRACTICAL NO :- 2
a) Aim :- Design A Webpage That Makes Use Of Table.
Source Code :-
<html>
<head>
<title> Student Details </title>
</head>
<body>
<h3> Aim :- DESIGN A WEBPAGE THAT MAKES USE OF TABLE </h3>
<table border="3" width="55">
<tr>
<td colspan="5" align="center"> STUDENT DETAILS </td>
</tr>
<tr>
<th> ID </th>
<th> NAME </th>
<th> AGE </th>
<th> CITY </th>
<th> MOBILE </th>
</tr>
<td align="center"> 14 </td>
<td align="center"> Sapna Gupta</td>
<td align="center"> 19 </td>
<td align="center"> Mumbai </td>
<td align="center"> 8947351252 </td>
</tr>
<tr>
<td align="center"> 15 </td>
<td align="center"> Nikhil Hadawale</td>
<td align="center"> 20</td>
<td align="center"> Navi Mumbai </td>
<td align="center"> 9998774854 </td>
</tr>
<tr>
<td align="center"> 07 </td>
<td align="center"> Yash Dhotre</td>
<td align="center"> 18 </td>
<td align="center"> Marine Dive </td>
<td align="center"> 9875157656 </td>
</tr>
</tr>
</body>
</html>
Output :-
b) Aim :- Form Tags (forms with various elements)
Source Code :-
<html>
<head>
<title> Student REGISTRATION FORM</title>
</head>
<body>
<marquee ><h1>Welcome To Sanpada College</h1></marquee>
<table border="2" align="center">
<form>
<tr>
<td colspan="2" align="center"><h3>STUDENT FORM</h3></td>
</tr>
<td>
FIRST NAME:</td><td><input type="text" id="first name">
</td>
</tr>
<tr>
<td>
MIDDLE NAME:
</td>
<td><input type="text" id="middle name">
</td>
</tr>
<tr>
<td>
LAST NAME:
</td>
<td><input type="text" id="LAST name"><br>
<br>
<td>
</tr>
<tr>
<td>
GENDER:</td>
<td>
<input type="radio" name="r" checked>
MALE<input type="radio" name="r">FEMALE
</td>
</tr>
<tr>
<td>
USERNAME:</td>
<td>
<input type="text" id="USERNAME">
</td>
</tr>
<tr>
<td>
DOB:</td>
<td>
<input type="text" id="DOB">
</td>
</tr>
<tr>
<td>
ADDRESS:</td>
<td>
<textarea></textarea>
</td>
</tr>
<tr colspan="2" align="center">
<td>
<input type="SUBMIT" value="submit" name="submit">
</td>
</tr>
</table>
</form>
</body>
</html>
Output :-
c) Aim :- Navigation Across Multiple Pages.
<html>
<head>
<title> Social Media </title>
T
<body>
<h1>Practical 2(C)-Navigation Across Multiple Pages:</h1>
<table border="4" >
<tr>
<th colspan="4" align= "centre"> Social Media </th>
</tr>
<tr>
<td><a href="https://www.facebook.com\mdquadirsailani"
target="_blank"><img src="D:\SYCS NIKHIL SANDIP HADAWALE\SYCS
WEB TECHNOLOGY\facebook.jpg"="60px" width="60px"></a></td>
<td><a href="https://www.instagram.com/quadirsailani/"
target="_blank"><img src=""D:\SYCS NIKHIL SANDIP HADAWALE\SYCS
WEB TECHNOLOGY\instagram.jpg" height="60px"
width="60px"></a></td>
</tr>
</table>
</body>
Output :-
PRACTICAL NO :- 3
a) Aim :- To Design Website Using CSS (Cascading Style Sheets).
Source Code :-
<html>
<head>
<style>
#divRed{
background-color:red;
color:white;
height:200px;
width=1200px;
font-family:georgia;
font-size:21px;
}
#divGreen{
background-color:Green;
color:black;
height:200px;
width=1200px;
font-family:georgia;
font-size:21px;
}
</style>
</head>
<body>
<div id="divRed">
We Are In The divRed
<p> This Paragraph Will Have A Red Background Color. And <br> TextColor Is
White</p>
</div>
<div id="divGreen">
We Are In The divGreen
<p> This Paragraph Will Have A Green Background Color. And <br> TextColor
Is Black</p>
We Are Still In The div Element.
</div>
</body>
<html>

Output :-
b) Aim :- CSS Properties To Change Fonts And Styles
Source Code :-
<html>
<head>
<style>
p.normal
{
font-family:TimesNewRoman;
font-style:normal;
font-size:25px;
}
p.italic
{
font-family:georgia;
font-style:italic;
font-size:35px;
color:blue;
}
</style>
</head>
<body>
<p class="normal"> Paragraph In Normal Form</p>
<p class="italic"> Italic Style </p>
This Is A Normal Paragraph.
</body>
</html>
Output :-
PRACTICAL NO :- 4

a) To Calculate Factorial Of A Given Number.


Source Code :-
<html>
<head>
<title>First JavaScript Program</title>
<script>
function Factorial() {
var i, no, fact;
fact = 1;
no = Number(document.getElementById("num").value);
for (i = 1; i <= no; i++) {
fact = fact * i;
}
alert('Factorial Of ' + no + ' is = ' + fact);
}
</script>
</head>
<body>
Enter Number: <input id="num">
<br><br>
<button onclick="Factorial()">Calculate Factorial</button>
</body>
</html>
Output :-
b) To Calculate The Fibonacci Series Up To n Terms :-
Source Code :-
<html>
<html>
<head>
<title>Fibonacci.html</title>
</head>
<body>
<script>
var number = parseInt(prompt('Enter The Number Of Terms: '));
var n1 = 0, n2 = 1, nextTerm;
document.write('Fibonacci Series: ');
for (var i = 1; i <= number; i++) {
document.write(n1 + " ");
nextTerm = n1 + n2;
n1 = n2;
n2 = nextTerm;
}
</script>
</body>
</html>
Output :-
Practical No :- 5
a) Aim :- To Work With The Strings In Html And Javascript.
Source Code :-
<html>
<head>
<title> Practical No :- 5 </title>
</head>
<body>
<script>
document.write("<h1> String Methods In JavaScript</h1>");

var str = "This Is String Literal";


document.write("<br>String Type Is: " + str);

var stringname = "<br>This String Is Using New Keyword";


document.write(stringname);
var College = "Sanpada College Of Commerce And Technology";
document.write("<br> College Name: " + College);

document.write("<br> Index Of 3rd Position: " + College.charAt(3));


var s1 = "Welcome To";
var s2 = "Oriental College Sanpada , Navi Mumbai";
var s3 = s1.concat(s2);
document.write("<br>" + s3);
var s5 = "Welcome To Sanpada College Of Commerce And Technology";
var res = s5.toUpperCase();
document.write("<br>" + res);
var res2 = s5.toLowerCase();
document.write("<br>" + res2);
</script>
</body>
</html>

Output :-
b) Aim :- To Work With Date & Time In Html And Javascript.
Source Code :-
<html>
<body>
<h1> Practical No :- 5.B - Date And Time </h1>
Display Current Time : <span id = 'txt'> </span>
<script>
var today = new Date();
var h = today.getHours();
var m = today.getMinutes();
var s = today.getSeconds();
document.getElementById('txt').innerHTML=h+":"+m+":"+s;
var date = new Date();
var day = date.getDate();
var month = date.getMonth()+1;
var year = getFullYear();
document.write("<br> Date Is : "+day+"/"+month+"/"+year);
</script>
</body>
</html>

Output :-
Practical No :- 6
Aim :- Write A PHP Script For Retrieving Data From HTML Forms.
Source Code :-
</html>
<body>
<h2> The XMLHttpRequestObject</h2>
<p id="demo"> Let AJAX Change This Text.</p>
<button type="button" onclick="loadDoc()"> Change Content </button>
<script>
function loadDoc()
{
var xhttp = new XMLHttpRequest();
xhttp.open("GET", "test.txt", false);
xhttp.send();
document.getElementById("demo").innerHTML = xhttp.responseText;
}
</script>
</body>
</html>
Output :-
Practical No :- 7
a) Aim:- Write A PHP And HTML Script To Design Registration Form And
Retrieve Data From.
Source Code :-
File Name :- regis.html
<html>
<head>
<title>Registration Form</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<h2>Registration Form</h2>
<form action="GetData.php" method="POST">
<b>First name:</b>
<input type="text" name="firstname">
<br/>
<b> Last name:</b>
<input type="text" name="lastname"><br/>
<b>Username</b>
<input type ="text" name="Username">
<br/>
<b>Email Id</b>
<input type="text" name="Email">
<br/>
<input type="submit" value="Submit">
</form>
</body>
</html>
Output :-

File Name :- getdata.php


<?php
echo "<h1>Registration Information</h1>";
$Fname = $_POST["firstname"];
$Lname = $_POST["lastname"];
$usname=$_POST["Username"];
$Email=$_POST["Email"];
echo $Fname."</br>";
echo $Lname."</br>";
echo $usname."</br>";
echo $Email."</br>";
?>
Output :-
b) Aim :- Write A PHP Script For Performing Certain Mathematical
Operations Such As Calculating Factorial.
Source Code :-
<?php
$n = 5;
$fact = 1;
$i;
for ($i=1;$i <= $n;$i++)
{
$fact = $fact * $i;
}
echo " Factorial Of $n Is = $fact";
?>
Output :-
c) Aim :- Write A PHP Script To Print Fibonacci Series up to 10 Terms.
Source Code :-
<?php
function printFibonacci($n)
{
$first = 0;
$second = 1;
echo "<h1>Print Fibonacci Series</h1>";
echo "Fibonacci Series \n";
echo $first.' '.$second.' ';
for($i = 2; $i < $n; $i++){
$third = $first + $second;
echo $third.' ';
$first = $second;
$second = $third;
}
}
printFibonacci(10);
?>
Output :-
d) Aim :- Write A HTML And PHP Script To Input Lower Bound & Upper Bound
& Print All The Prime Number Between Lower Bound and Upper Bound.
Source Code :-
<html>
<head>
<title>Range of Prime Numbers in PHP</title>
</head>
<body>
<h2>Print Prime Numbers Between Given Range</h2>
<form method="post" action="prime.php" name="prime_me">
<input type="text" name="lower" >
<input type="text" name="upper" >
<br><br>
<input type="submit" name="check" value="Ok">
</form>
<h3> PRIME NUMBERS </h3>
<?php
if(isset($_POST['check']))
{
$a=$_POST['lower'];
$b=$_POST['upper'];
$flag=0;
for($a;$a<$b;$a++)
{
for($j=2;$j<$a;$j++)
{
if($a%$j==0)
{
$flag=1;
}
}
if($flag==0)
{
echo " ".$a." ";
}
$flag=0;
}
}
?>
</body>
</html>
Output :-
e) Aim :- Write A PHP Script For Performing Certain Mathematical Operations
To Calculate Reverse Of A Number.
Source Code :-
<html>
<body>
<h3> Practical No 8(b) : To Reverse A Number</h3>
<?php
$num = 123456;
$revnum = 0;
while($num > 1)
{
$rem = $num % 10;
$revnum = ($revnum * 10) + $rem;
$num = ($num / 10);
}
echo"Reverse Number Of $num is : $revnum";
?>
</body>
</html>
Output :-
Practical No :- 8
Aim :- Write PHP Script For Storing and Retrieving Cookies.
Source Code :-
<?php
setcookie("College","Sanpada College Of Commerce And Technology,Navi
Mumbai");
?>
<html>
<body>
<?php
if(!isset($_COOKIE["College"]))
{
echo"Sorry, Cookie Is Not Found!";
}
else
{
echo"<br/> Cookie Value : ".$_COOKIE["College"];
}
?>
</body>
</html>
Output :-

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy