1. 1) Write a program to create a online website for AP Tourism
AIM: create a online website for AP tourism
PROGRAM:
Top.html:
<html>
<head>
<title>top</title>
</head>
<body background="sunrise1.jpg">
<h1 style="color:red;font-weight:bold;text-align:center;">AP TOURISM</h1>
<marquee align="left">***Andhra Pradesh Tourism Development Corporation***</marquee>
<img src="Andhra-Pradesh-Tourism-Policy-2015.jpg" width="150" height="100" alt="AP
toursim" align="right">
<div style="color:purple;font-weight:bold;">
Welcome<br>
To Andhra Pradesh<br>
Tourism<br>
Official Website<br>
Toll Free : 1800-42-545454
</div>
<div align="center">
<a href="aboutus.html"><font color="blue">About
Us</font></a>
<a href="contactus.html"><font color="blue">Contact
Us</font></a>
<a href="booknow.html"><font color="blue">Book
Now</font></a>
<a href="exlplore.html"><font
color="blue">Explore</font></a>
</div>
</body>
2. Aboutus.html
<html>
<head>
<title>AboutUs</title>
</head>
<body background="about-us2.jpg" height="900" width="1000">
<h1 style="color:red;font-weight:bold;text-align:center;">AP TOURISM</h1>
<div align="center">
<a href="top.html"><font color="blue">Home</font></a>
<a href="aboutus.html"><font color="blue">About
Us</font></a>
<a href="contactus.html"><font color="blue">Contact
Us</font></a>
</div>
<p>
<b style="color:blue;font-weight:bold;"> Vision & Mission</b><br><br>
<b style="color:blue;">Vision</b><br>
<p>
Tourism is considered an engine of development and a catalyst to economic prosperity of a state.
Tourism not only refreshes the mind, but it also ushers happiness, relaxation, enjoyment and offers
a new experience etc. to the tourists.
It results in all round growth by means of an economic multiplier effect that percolates to various
stake-holders and other sectors such as airlines, railways, surface cruises, hotels etc.
The Vision of Andhra Pradesh tourism is to promote steady and sustained growth phase of the
travel and tourism sector in Andhra Pradesh making the destinations more accessible, more
attractive with many facilities and amenities for the tourists worldwide.
</p>
<b style="color:blue;">Vision Statement</b>
<p>
"To maintain its current position as the most sought-after tourism destination for an authentic,
luxurious, and personalized feel and experience of Andhra Pradesh for travelers from all regions."
3. Tourism is a major phenomenon in the modern society that has emerged as a successful economic
activity carrying immense global importance. There is hardly any other field of activity, which has
so many people involved directly or indirectly.
Tourism finds a niche for itself as an effective instrument in terms of generating employment,
earning revenue and foreign exchange, enhance environment, preserving culture and tradition
thereby resulting in overall development. Tourism is regarded as one of the world's largest and
fastest growing industries and Andhra Pradesh Tourism has grown by leaps and bounds over last
few years and is also gearing up to achieve significant progress in the field due to a many
encouraging factors.
Andhra Pradesh has vast geographical area combined with great historical and cultural heritage,
which are excellent conditions for more growth in this sector. The vision of Andhra Pradesh
tourism is to serve as a guiding force that offers a clear vision and direction for optimizing the
tourism potential of this state in a sustainable manner.
</p>
<b style="color:blue;">Mission</b>
<p>
According to Government of India estimates, every one crore that is invested in Tourism creates
475 jobs compared to 126 jobs from manufacturing sector, which proves the potential of this
sector.
</p>
<b style="color:blue;">Goals</b>
<ol type="circle">
<li>Make Andhra Pradesh travel and tourism more popular and attractive</li>
<li> Make the public gain more awareness regarding the importance and usefulness of travel and
tourism</li>
<li> Use more publicity to promote tourism destinations including the facilities and amenities
available</li>
<li> Develop the travel and tourism industry in Andhra Pradesh, making it more profitable and
competent</li>
<li> Promote eco-friendly and responsible tourism including a profit share to the local
population</li>
<li> Strengthen the existing tourism infrastructure in the Andhra Pradesh</li>
</p>
</body>
</html>
7. 2) Create a webpage in html describe your MCA department
a) Use paragraph and list tags
b) Apply various colors to distinguish keywords
c) Use header tags
d) Insert a image map and provide hotspots
e) At the bottom create a link to the user to top of the page
AIM: To demonstrate a webpage for MCA
PROGRAM:
mapping.html
<html>
<head>
<title>mapping</title>
</head>
<body>
<img src="MCA-banner.jpg" usemap="#MCA"/>
<map name="MCA">
<area href="F:harikawebpage.html" target="_blank"
shape="square" coords="372,313,367,355">
</map>
</body>
</html>
Webpage.html
<html>
<head>
<title>mapping</title>
</head>
<body>
<img src="MCA-banner.jpg" usemap="#MCA"/>
<map name="MCA">
10. 3) Write a program to demonstrate concept of formatting tags
AIM: To demonstrate concept of formatting tags
PROGRAM:
<html>
<head>
<title>using formating tags</title>
</head>
<body bgcolor="blue">
<h1 align="center"><font color="orange"><u>KBN INFO</u></font></h1>
<h2><font color="yellow">ABOUT US</font></h2>
<p>
<font type="arial" color="white" size="5">
<strong>
"Kakarparthi Bhavanarayana College with its four decades reputation has been leaving no stone
unturned to achieve the pre-set goal of transforming every student into a great leader by imparting
rich and qualitative education” . After establishing college in 1965 at vijayawada it bagged many
laurels to its credit and created many responsible citizens. Every educating student requires
attention to virtues, ethics, character and integrity.“The college had been sponsored by a century-
old society ... SKPVV Hindu High School's Committee “.
</strong>
</font>
</p>
<h2><font color="red" size="5">FACILITIES</font></h2>
<p>
<ul>
<font color="YELLOW" size="5">
<li type="disc">Well furnished classrooms.</li>
<li>Experienced faculties</li>
<li>Hostel facilities.</li>
<li>Book bank facility</li>
<li>College conducts state level quiz competition</li>
11. <li> Campus has gym and healthcare centre</li>
<li>Well equipped labs with modern technologies.</li>
<li>Spacious playground with indoor and outdoor sports facilities.</li>
<li>Parents can get to know their childrens attendance and academic performance through
phone.</li>
<li>The campus is monitored by CCTV system.</li>
<li>The college received 2nd Best Library award from Acharya Nagarjuna University.</li>
<li>Guest lectures and Industrial visits are arranged.</li>
<li>The college has NCC, NSS and other activities.</li>
<li>The library of KBN college is housed with huge collection of books, national and
international journals.</li>
</p>
</ul>
</font>
<h2><font type="Georgia" color="WHITE" size="5">PLACEMENTS</font></h2>
<font color="ORANGE" size="5">
<p>
<em>
Every year KBN college has conducting placements.so many companies are there and recurit the
students.companies are like:tcs,Tech mahindra,Accenture,hdfc bank,wipro,dell,muthoot,efftronics
etc.......
</em>
</p>
</font>
</body>
</html>
20. 6) Write a javascript to perform event handling
AIM: To demonstrate a concept of event handling
PROGRAM:
<html>
<head>
<title>Event Handling </title>
</head>
<body onLoad='alert("This is Event Handling Program")'>
<h1 align="center"> Event handling </h1>
<ul>
<br><li> onClick Event:
<input type="button" value="Click here" onClick='alert("Clicked")'><br><br>
<li> onDblClick Event :
<input type="button" value="Double click here" onDblClick='alert("Double Clicked")'><br><br>
<li> onFocus Event:
<input type="text" value="click here" onFocus='alert("Focus gained")'><br><br>
<li> onChange Event:
<input type="text" value="alter the text here" size="20" onChange='alert("changed")'><br><br>
<li> onReset Event :
<form onReset='alert("This will reset the form!")'>
<input type="text">
<input type="reset" value="reset">
</form>
<li> onSelect Event :
<input type="text" value="select me" size="20" onSelect='alert("Text Selected")'><br><br>
<li> onMouseover :
<br> put your mouse over <a href="www.gmail.com" onMouseover="window.status='hi this is
Sudhakar';return true">here</a>and look at the status bar<br><br>
<li> onMouseOut
21. <br> Put your Mouse Out<a href="www.gmail.com"onMouseOut="window.status='you left the
link!';return true">here</a>and then take mouse pointer away<br><br>
<li> on Submit event :
<form onSubmit='alert("submitted")'>
<input type="text">
<input type="submit" value="submit">
</form>
<br>
<br>
</ul>
</body>
</html>
23. 7) Write a javascript to perform string functions
AIM: To demonstrate string functions
PROGRAM
<html>
<head><title>String Functions</title>
</head>
<body bgcolor="yellow">
<h1 align="center"> String Functions </h1>
<h4>
<script language="javascript">
var str=new String("This is a String Function Program");
document.writeln("charAt(0) is "+str.charAt(0));
var index=str.indexOf("Program");
document.writeln("<br> Index of Program is : " +index);
index=str.lastIndexOf("is");
document.writeln("<br> Index of is :" +index);
str1="Apple,Banana are good for Health";
var split_str=str1.split(" ",3);
document.writeln("<br> The Splitted elements are :" +split_str);
document.writeln("<br> substring(1,2) is " +str.substr(1,2));
document.writeln("<br> substring(1,3) is " +str.substr(1,3));
document.writeln("<br> Uppercase elements is: "+str.toUpperCase(str1));
document.writeln("<br> Lowercase elements is: " +str.toLowerCase(str1));
</script>
</h4>
</body>
</html>
24. OUTPUT:
charAt(0) is T
Index of Program is : 26
Index of is :5
The Splitted elements are :Apple,Banana,are,good
substring(1,2) is hi
substring(1,3) is his
Uppercase elements is: THIS IS A STRING FUNCTION PROGRAM
Lowercase elements is: this is a string function program
25. 8) Write a program to demonstrate concept of CSS
AIM: To demonstrate a concept of CSS
PROGRAM: external.css
<html>
<head>
<title>ecss</title>
<link rel="stylesheet" type="text/css" href="ex.css">
</head>
<body>
<h1><center>External style sheets</center></h1>
<p>web technologies that relate to the interface between web servers and their clients.
This information includes markup languages, programming interfaces and languages,
and standards for document identification and display.</p>
<p>CSS is a stylesheet language that describes the presentation of an HTML (or XML) document.
CSS describes how elements must be rendered on screen, on paper, or in other media.
This tutorial will teach you CSS from basic to advanced.</p>
<p>Cascading Style Sheets (CSS) is a simple mechanism for adding style (e.g., fonts, colors,
spacing) to Web documents. These pages contain information on how to learn and use CSS and on
available software. They also contain news from the CSS working group. </p>
</body>
</html>
31. 9) Write a program for date object
AIM: To demonstrate a concept of date object
Program:
<html>
<head>
<script language="javascript">
function hours()
{
var a=new Date();
var hours=a.getHours();
if(hours>=5&&hours<12)
document.writeln("Good morning");
else if(hours>=12&&hours<17)
document.writeln("Good afternoon");
else if(hours>=17&&hours<21)
document.writeln("Good evening");
else
document.writeln("Good night");
}
</script>
</head>
<body>
<script language="javascript">
hours();
</script>
</body>
</html>
33. 10) Write a program for sorting of arrays
AIM: To demonstrate a concept of sorting arrays
PROGRAM:
<html>
<head>
<title>Sorting</title>
</head>
<body>
<script language="javascript">
var i,j,n,t;
var a=new Array(5);
n=parseInt(window.prompt("enter n value"));
for(i=0;i<n;i++)
a[i]=parseInt(window.prompt("enter a value"));
for(i=0;i<n;i++)
for(j=i+1;j<n;j++)
{
if(a[i]>a[j])
{
t=a[i];
a[i]=a[j];
a[j]=t;
}
}
for(i=0;i<n;i++)
document.writeln("<br>"+a[i]);
</script>
</body>
35. 11)Write a php program using session variables
AIM: To set session variables in php and access session variables
PROGRAM: DEMO1.PHP
//To set session variables//
<html>
<body>
<?php
// Start the session
session_start();
?>
<!DOCTYPE html>
<html>
<body>
<?php
// Set session variables
$_SESSION["favcolor"] = "green";
$_SESSION["favanimal"] = "cat";
echo "Session variables are set.";
?>
</body>
</html>
PROCESS FOR PHP EXECUTION:
1) Write php program in notepad
2) Save file as demo1.php in C:xampphtdocs as “All files”
3) Open internet explorer type in address field as ” http://localhost:8088/demo1.php”
37. DEMO2.PHP
//Display of session variables//
<html>
<body>
<?php
session_start();
?>
<!DOCTYPE html>
<html>
<body>
<?php
// Echo session variables that were set on previous page
echo "Favorite color is " . $_SESSION["favcolor"] . ".<br>";
echo "Favorite animal is " . $_SESSION["favanimal"] . ".";
?>
</body>
</html>
PROCESS FOR PHP EXECUTION:
4) Write php program in notepad
5) Save file as demo1.php in C:xampphtdocs as “All files”
6) Open internet explorer type in address field as ” http://localhost:8088/demo2.php”
39. 12) Write a program in php to demonstrate cookies
AIM: To set a new cookie in PHP
PROGRAM:
<html>
<body>
<?php
$cookie_name = "user";
$cookie_value = "HARRY POTTER";
setcookie($cookie_name, $cookie_value, time() + (86400 * 30), "/");
?>
<html>
<body>
<?php
if(!isset($_COOKIE[$cookie_name])) {
echo "Cookie named '" . $cookie_name . "' is not set!";
} else {
echo "Cookie '" . $cookie_name . "' is set!<br>";
echo "Value is: " . $_COOKIE[$cookie_name];
}
?>
</body>
</html>