Você está na página 1de 10

MBA IT – 108 WEB TECHNOLOGY AND MULTIMEDIA

SECTION 1
Q1. Define HTML
Ans.
HTML is the standard markup language for creating Web pages.

 HTML stands for Hyper Text Markup Language


 HTML describes the structure of Web pages using markup
 HTML elements are the building blocks of HTML pages
 HTML elements are represented by tags
 HTML tags label pieces of content such as "heading", "paragraph", "table", and so on
 Browsers do not display the HTML tags, but use them to render the content of the
page

Q2. What are SMTP and POP3?


Ans.
POP and SMTP are the two protocols which take care of the email flow (send and
receive respectively) on the internet. SMTP (“Simple Mail Transfer Protocol”) is
used for sending and delivering from a client to a server via port 25: it’s the
outgoing server. On the contrary, POP (“Post Office Protocol”) allows the user to
pick up the message and download it into his own inbox: it’s the incoming server.
The latest version of the Post Office Protocol is named POP3, and it’s been used
since 1996; it uses port 110. To set up a mail client it’s necessary to configure both
SMTP and POP providing their settings. Here’s an example with Mozilla
Thunderbird “Outgoing server” item, selected from “Account settings” in the
“Tools” menu

Q3. What is E-Commerce?


Ans.
Ecommerce, also known as electronic commerce or internet commerce, refers to the
buying and selling of goods or services using the internet, and the transfer of money and
data to execute these transactions. Ecommerce is often used to refer to the sale of
physical products online, but it can also describe any kind of commercial transaction that
is facilitated through the internet.

Whereas e-business refers to all aspects of operating an online business, ecommerce


refers specifically to the transaction of goods and services.

The history of ecommerce begins with the first ever online sale: on the August 11, 1994 a
man sold a CD by the band Sting to his friend through his website NetMarket, an
American retail platform. This is the first example of a consumer purchasing a product
from a business through the World Wide Web—or “ecommerce” as we commonly know it
today.

Q4. Define RDBMS.

Ans.
Stands for "Relational Database Management System." An RDBMS is a DBMS designed specifically
for relational databases. Therefore, RDBMSes are a subset of DBMSes.
A relational database refers to a databasethat stores data in a structured format,
using rows and columns. This makes it easy to locate and access specific values within the database.
It is "relational" because the values within each table are related to each other. Tables may also be
related to other tables. The relational structure makes it possible to run queries across multiple
tables at once.
While a relational database describes the type of database an RDMBS manages, the RDBMS refers
to the database program itself. It is the software that executes queries on the data, including
adding, updating, and searching for values. An RDBMS may also provide a visual representation of
the data. For example, it may display data in a tables like a spreadsheet, allowing you to view and
even edit individual values in the table. Some RDMBS programs allow you to create forms that can
streamline entering, editing, and deleting data.
Most well known DBMS applications fall into the RDBMS category. Examples include Oracle
Database, MySQL, Microsoft SQL Server, and IBM DB2. Some of these programs support non-
relational databases, but they are primarily used for relational database management.

Q5. What are servlets?


Ans.
Q6. What are Get and Post methods?
Ans.
HTTP POST requests supply additional data from the client (browser) to the server in
the message body. In contrast, GET requests include all required data in the URL.
Forms in HTML can use either method by
specifying method="POST" or method="GET" (default) in the <form> element. The
method specified determines how form data is submitted to the server. When the
method is GET, all form data is encoded into the URL, appended to the action URL as
query string parameters. With POST, form data appears within the message body of
the HTTP request.

Note that the query string (name/value pairs) is sent in the URL of a GET request:

/test/demo_form.php?name1=value1&name2=value2

The data sent to the server with POST is stored in the request body of the HTTP request:

POST /test/demo_form.php HTTP/1.1


Host: w3schools.com
name1=value1&name2=value2

SECTION B
Q1. Define and discuss about following:

i. HTTP ii. IMAP

Ans.

HTTP –

HTTP (Hypertext Transfer Protocol) is the set of rules for transferring files (text, graphic
images, sound, video, and other multimedia files) on the World Wide Web. As soon as a
Web user opens their Web browser, the user is indirectly making use of HTTP. HTTP is
an application protocol that runs on top of the TCP/IP suite of protocols (the foundation
protocols for the Internet).

HTTP concepts include (as the Hypertext part of the name implies) the idea that files can
contain references to other files whose selection will elicit additional transfer requests.
Any Web servermachine contains, in addition to the Web page files it can serve, an
HTTP daemon, a program that is designed to wait for HTTP requests and handle them
when they arrive. Your Web browseris an HTTP client, sending requests to server
machines. When the browser user enters file requests by either "opening" a Web file
(typing in a Uniform Resource Locator or URL) or clicking on a hypertext link, the browser
builds an HTTP request and sends it to the Internet Protocol address (IP address)
indicated by the URL. The HTTP daemon in the destination server machine receives the
request and sends back the requested file or files associated with the request. (A Web
page often consists of more than one file.)

The latest version of HTTP is HTTP 1.1.

IMAP

IMAP (Internet Message Access Protocol) is a standard email protocol that stores email
messages on a mail server, but allows the end user to view and manipulate the messages
as though they were stored locally on the end user's computing device(s). This allows
users to organize messages into folders, have multiple client applications know which
messages have been read, flag messages for urgency or follow-up and save draft
messages on the server.

IMAP can be contrasted with another client/server email protocol, Post Office Protocol 3
(POP3). With POP3, mail is saved for the end user in a single mailbox on the server and
moved to the end user's device when the mail client opens. While POP3 can be thought of
as a "store-and-forward" service, IMAP can be thought of as a remote file server.

Most implementations of IMAP support multiple logins; this allows the end user to
simultaneously connect to the email server with different devices. For example, the end
user could connect to the mail server with his Outlook iPhone app and his Outlook
desktop client at the same time. The details for how to handle multiple connections are not
specified by the protocol but are instead left to the developers of the mail client.

Even though IMAP has an authentication mechanism, the authentication process can
easily be circumvented by anyone who knows how to steal a password by using a protocol
analyzer because the client’s username and password are transmitted as clear text. In
an Exchange Server environment, administrators can work around this security flaw by
using Secure Sockets Layer (SSL) encryption for IMAP.

Q2. Differentiate between Servlet and JSP.


Ans.

Java Servlets are programs that run on a Web or Application server and act as a middle layer
between a request coming from a Web browser or other HTTP client and databases or applications on
the HTTP server.

Using Servlets, you can collect input from users through web page forms, present records from a
database or another source, and create web pages dynamically.

JavaServer Pages (JSP) is a technology for developing web pages that support dynamic content
which helps developers insert java code in HTML pages by making use of special JSP tags, most of
which start with <% and end with %>.
JSP are webpages similar to aspx/php pages which run at server side. Javascript or Html code in JSP
pages runs at client side.

Key Differences :

 Servlet is html in java whereas JSP is java in html.


 Servlets run faster compared to JSP
 JSP can be compiled into Java Servlets
 It’s easier to code in JSP than in Java Servlets
 JSP is a webpage scripting language that can generate dynamic content while Servlets are
Java programs that are already compiled which also creates dynamic web content
 In MVC, jsp acts as a view and servlet acts as a controller.
 JSP are generally preferred when there is not much processing of data required. But servlets
are best for use when there is more processing and manipulation involved.
 The advantage of JSP programming over servlets is that we can build custom tags which can
directly call Java beans. There is no such facility in servlets.
 We can achieve functionality of JSP at client side by running JavaScript at client side. There
are no such methods for servlets.
 A servlet is like any other Java class. You put HTML into print statements like you
use System.out or how JavaScript uses document.write. A JSP technically gets converted
to a servlet but it looks more like PHP files where you embed the Java into HTML.
Q3. What is the lifecycle of a typical web application written in ASP?.

Ans.
ASP.NET life cycle specifies, how:

 ASP.NET processes pages to produce dynamic output

 The application and its pages are instantiated and processed

 ASP.NET compiles the pages dynamically

The ASP.NET life cycle could be divided into two groups:

 Application Life Cycle

 Page Life Cycle

ASP.NET Application Life Cycle


The application life cycle has the following stages:

 User makes a request for accessing application resource, a page. Browser sends this request to
the web server.

 A unified pipeline receives the first request and the following events take place:

o An object of the class ApplicationManager is created.

o An object of the class HostingEnvironment is created to provide information regarding


the resources.

o Top level items in the application are compiled.

 Response objects are created. The application objects such as HttpContext, HttpRequest and
HttpResponse are created and initialized.

 An instance of the HttpApplication object is created and assigned to the request.

 The request is processed by the HttpApplication class. Different events are raised by this class
for processing the request.
Q4. Discuss event handling mechanism of JavaScript using an example.
Ans

JavaScript's interaction with HTML is handled through events that occur when the user or
the browser manipulates a page.

When the page loads, it is called an event. When the user clicks a button, that click too
is an event. Other examples include events like pressing any key, closing a window,
resizing a window, etc.

Developers can use these events to execute JavaScript coded responses, which cause
buttons to close windows, messages to be displayed to users, data to be validated, and
virtually any other type of response imaginable.

Events are a part of the Document Object Model (DOM) Level 3 and every HTML element
contains a set of events which can trigger JavaScript Code.

onclick Event Type


This is the most frequently used event type which occurs when a user clicks the left
button of his mouse. You can put your validation, warning etc., against this event type.

<html>

<head>

<script type = "text/javascript">

<!--

function sayHello() {

alert("Hello World")

//-->

</script>

</head>

<body>

<p>Click the following button and see result</p>

<form>
<input type = "button" onclick = "sayHello()" value = "Say Hello" />

</form>

</body>

</html>

onsubmit Event Type


onsubmit is an event that occurs when you try to submit a form. You can put your form
validation against this event type.

<html>

<head>

<script type = "text/javascript">

<!--

function validation() {

all validation goes here

.........

return either true or false

//-->

</script>

</head>

<body>

<form method = "POST" action = "t.cgi" onsubmit = "return validate()">

.......

<input type = "submit" value = "Submit" />

</form>

</body>

</html>

onmouseover and onmouseout


These two event types will help you create nice effects with images or even with text as
well. The onmouseover event triggers when you bring your mouse over any element
and the onmouseout triggers when you move your mouse out from that element.

<html>

<head>

<script type = "text/javascript">

<!--

function over() {

document.write ("Mouse Over");

function out() {

document.write ("Mouse Out");

//-->

</script>

</head>

<body>

<p>Bring your mouse inside the division to see the result:</p>

<div onmouseover = "over()" onmouseout = "out()">

<h2> This is inside the division </h2>

</div>

</body>

</html>

Você também pode gostar