Sei sulla pagina 1di 15

ANNEXURE

Q1. What is the use of HTML 5 over HTML 4?


Answer: Following are the new features of HTML5:

Simplified Syntax: The simpler doctype declaration is just one of the many
novelties in HTML5. Now you need to write only: <!doctype html> and this is it.

The New <canvas> Element: This is what killed Flash.

The <header> and <footer> Elements: For good or bad, HTML5


has acknowledged the new web anatomy. With HTML5, <header> and <footer>
are specifically marked for such. Because of this, it is unnecessary to identify
these two elements with a <div> tag.

New <section> and <article> Elements: Again, HTML5 has adopted the popular
web standard. <Section> and <article> allows you to mark specific areas of your
layout as such.

New <menu> and <figure> Elements: <menu> can be used for your main menu,
but it can also be used for toolbars and context menus. The <figure> element is
another way to arrange text and images.

New <audio> and <video> Elements: Embedded audio and video has never
been easier. There are also some new multimedia elements and attributes, such as
<track>, that provides text tracks for the video element. With these additions
HTML5 is definitely getting more and more Web 2.0-friendly.

New Forms: the new <form> and <forminput> elements are looking good. If you
do much with forms, you may want to take a look at what these have to offer.

Q2. What happens when characters are passed in a phone number


field?
Answer: Error message is shown displaying that the phone number is invalid.

Q3. What kind of payment methodology is used?


Answer: Sandbox PayPal account is added and option of cash on delivery is given.

Q4. What is the use of CSS3?


Answer: Cascading Style Sheets, fondly referred to as CSS, is a simple design language
intended to simplify the process of making web pages presentable. CSS handles the look and
feel part of a web page. Using CSS, you can control the color of the text, the style of fonts,
the spacing between paragraphs, how columns are sized and laid out, what background
images or colors are used, layout designs, and variations in display for different devices and
screen sizes as well as a variety of other effects. CSS is easy to learn and understand but it
provides powerful control over the presentation of an HTML document. Most commonly,
CSS is combined with the markup languages HTML or XHTML.
ADVANTAGES:
CSS saves time you can write CSS once and then reuse same sheet in multiple HTML
pages. You can define a style for each HTML element and apply it to as many Web pages as
you want.
Pages load faster If you are using CSS, you do not need to write HTML tag attributes
every time. Just write one CSS rule of a tag and apply it to all the occurrences of that tag. So
less code means faster download times.
Easy maintenance To make a global change, simply change the style, and all elements in
all the web pages will be updated automatically.
Superior styles to HTML CSS has a much wider array of attributes than HTML, so you
can give a far better look to your HTML page in comparison to HTML attributes.
Multiple Device Compatibility Style sheets allow content to be optimized for more than
one type of device. By using the same HTML document, different versions of a website can
be presented for handheld devices such as PDAs and cell phones or for printing.
Global web standards Now HTML attributes are being deprecated and it is being
recommended to use CSS. So its a good idea to start using CSS in all the HTML pages to
make them compatible to future browsers.

Offline Browsing CSS can store web applications locally with the help of an offline cache.
Using of this, we can view offline websites. The cache also ensures faster loading and better
overall performance of the website.
Platform Independence The Script offer consistent platform independence and can
support latest browsers as well.
CSS VERSIONS:
Cascading Style Sheets, level 1 (CSS1) was came out of W3C as a recommendation in
December 1996. This version describes the CSS language as well as a simple visual
formatting model for all the HTML tags.
CSS2 was became a W3C recommendation in May 1998 and builds on CSS1. This version
adds support for media-specific style sheets e.g. printers and aural devices, downloadable
fonts, element positioning and tables.
CSS3 was became a W3C recommendation in June 1999 and builds on older versions CSS. It
has divided into documentations is called as Modules and here each module having new
extension features defined in CSS2.

Q5. What level of normalization is used in the project?


Answer: Data normalization is a process in which data attributes within a data model are
organized to increase the cohesion of entity types. In other words, the goal of data
normalization is to reduce and even eliminate data redundancy, an important
consideration for application developers because it is incredibly difficult to stores objects
in a relational database that maintains the same information in several places.

Table 1. Data Normalization Rules.


Level

Rule

First normal

An entity type is in 1NF when it contains no repeating groups

form (1NF)

of data.

Second normal
form (2NF)

Third normal
form (3NF)

An entity type is in 2NF when it is in 1NF and when all of its


non-key attributes are fully dependent on its primary key.

An entity type is in 3NF when it is in 2NF and when all of its


attributes are directly dependent on the primary key.

Why Data Normalization?


The advantage of having a highly normalized data schema is that information is stored in
one place and one place only, reducing the possibility of inconsistent data. Furthermore,
highly-normalized data schemas in general are closer conceptually to object-oriented
schemas because the object-oriented goals of promoting high cohesion and loose
coupling between classes results in similar solutions (at least from a data point of
view). This generally makes it easier to map your objects to your data schema.

DENORMALIZATION
From a purist point of view you want to normalize your data structures as much as
possible, but from a practical point of view you will find that you need to 'back out" of
some of your normalizations for performance reasons. This is called "de-normalization".

Q6. How long a session will retain after a login? What default value is
set for session start ()?
Answer: It depends on the server configuration or the relevant directives
(session.gc_maxlifetime) in php.ini. Typically the default is 24 minutes (1440 seconds),
but webhost may have altered the default to something else. To change default settings is
pretty easy. First, set session.gc_maxlifetime to the desired session timeout, in seconds.
E.g. if you want your sessions to timeout after 30 minutes, set session.gc_maxlifetime to
1800 (60 seconds in a minute * 30 minutes = 1,800 seconds).

Q7. What are the different joins in MYSQL? What join is used in this
project to join two tables?
Answer: JOIN is an SQL keyword used to query data from two or more related tables.
A well-designed database will provide a number of tables containing related data. A very
simple example would be users (students) and course enrollments:
user table:
id

name

course

Alice

Bob

Caroline

David

Emma

(NULL)

MySQL table creation code:


CREATE TABLE `user` (

`id` smallint (5) unsigned NOT NULL AUTO_INCREMENT,


`name` varchar (30) NOT NULL,
`course` smallint (5) unsigned DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB;
The course number relates to a subject being taken in a course table.
course table:
id

name

HTML5

CSS3

JavaScript

PHP

MySQL

MySQL table creation code:


CREATE TABLE `course` (
`id` smallint (5) unsigned NOT NULL AUTO_INCREMENT,
`name` varchar (50) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB;

JOINs allow us to query this data in a number of ways.


INNER JOIN (or just JOIN)

The most frequently used clause is INNER JOIN. This produces a set of records which
match in both the user and course tables, i.e. all users who are enrolled on a course:
SELECT user.name, course.name
FROM `user`
INNER JOIN `course` on user.course = course.id;
Result:

LEFT JOIN

user.name

course.name

Alice

HTML5

Bob

HTML5

Carline

CSS3

David

MySQL

A LEFT JOIN produces a set of records which matches every entry in the left table (user)
regardless of any matching entry in the right table (course):
SELECT user.name, course.name
FROM `user`
LEFT JOIN `course` on user.course = course.id;
Result:
user.name

course.name

Alice

HTML5

Bob

HTML5

Carline

CSS3

David

MySQL

Emma

(NULL)

RIGHT JOIN

A RIGHT JOIN produces a set of records which matches every entry in the right table
(course) regardless of any matching entry in the left table (user):
SELECT user.name, course.name
FROM `user`
RIGHT JOIN `course` on user.course = course.id;
Result:
user.name

course.name

Alice

HTML5

Bob

HTML5

Carline

CSS3

(NULL)

JavaScript

(NULL)

PHP

David

MySQL

RIGHT JOINs are rarely used since you can express the same result using a LEFT JOIN.
SELECT user.name, course.name
FROM `course`
LEFT JOIN `user` on user.course = course.id;
For example, count the number of students enrolled on each course:
SELECT course.name, COUNT(user.name)
FROM `course`
LEFT JOIN `user` ON user.course = course.id

GROUP BY course.id;
Result:
course.name

count()

HTML5

CSS3

JavaScript

PHP

MySQL

OUTER JOIN (or FULL OUTER JOIN)

OUTER JOIN which returns all records in both tables regardless of any match. Where no
match exists, the missing side will contain NULL. OUTER JOIN is less useful than
INNER, LEFT or RIGHT and its not implemented in MySQL. However, you can work
around this restriction using the UNION of a LEFT and RIGHT JOIN, e.g.
SELECT user.name, course.name
FROM `user`
LEFT JOIN `course` on user.course = course.id
UNION
SELECT user.name, course.name
FROM `user`
RIGHT JOIN `course` on user.course = course.id;
Result:

user.name

course.name

Alice

HTML5

Bob

HTML5

Carline

CSS3

David

MySQL

Emma

(NULL)

(NULL)

JavaScript

(NULL)

PHP

Q8. What is the use of POST and GET method?


Answer: There are two ways the browser client can send information to the web server.

The GET Method

The POST Method

Before the browser sends the information, it encodes it using a scheme called URL
encoding. In this scheme, name/value pairs are joined with equal signs and different pairs
are separated by the ampersand. Spaces are removed and replaced with the + character
and any other no alphanumeric characters are replaced with a hexadecimal values. After
the information is encoded it is sent to the server.
The GET Method
The GET method sends the encoded user information appended to the page request. The
page and the encoded information are separated by the ? Character.
The GET method produces a long string that appears in your server logs, in the browser's
Location: box.

The GET method is restricted to send up to 1024 characters only.

Never use GET method if you have password or other sensitive information to be
sent to the server.

GET can't be used to send binary data, like images or word documents, to the
server.

The data sent by GET method can be accessed using QUERY_STRING


environment variable.

The PHP provides $_GET associative array to access all the sent information
using GET method.

The POST Method


The POST method transfers information via HTTP headers. The information is encoded
as described in case of GET method and put into a header called QUERY_STRING.

The POST method does not have any restriction on data size to be sent.

The POST method can be used to send ASCII as well as binary data.

The data sent by POST method goes through HTTP header so security depends on
HTTP protocol. By using Secure HTTP you can make sure that your information
is secure.

The PHP provides $_POST associative array to access all the sent information
using POST method.

Q9. What is the difference between include and include_once?


Answer: The include_once () statement includes and evaluates the specified file during
the execution of the script.

This is a behaviour similar to the include () statement, with the only difference being that
if the code from a file has already been included, it will not be included again. As the
name suggests, it will be included just once include_once.

Q10. Why *-1 and 1-1 relation is used?


Answer: Types of Relationships:
a. One-One Relationship (1-1 Relationship)
b. One-Many Relationship (1-M Relationship)
c. Many-Many Relationship (M-M Relationship)
One-One Relationship (1-1 Relationship)
One-to-One (1-1) relationship is defined as the relationship between two tables where both
the tables should be associated with each other based on only one matching row. This
relationship can be created using Primary key-Unique foreign key constraints. With One-toOne Relationship in SQL Server, for example, a person can have only one passport.
One-Many Relationship (1-M Relationship)
The One-to-Many relationship is defined as a relationship between two tables where a row
from one table can have multiple matching rows in another table. This relationship can be
created using Primary key-Foreign key relationship.

PERSONAL DETAILS

NAME: Praveena Ratiya


USN: 1GA14SCS02
COURSE: Masters of Technology
SPECIALIZATION: Computer Science & Engineering
COLLEGE NAME: Global Academy of Technology
Address: Mysore Rd, Ideal Homes Township,
Bengaluru, Karnataka 560098
UNIVERSITY: Visvesvaraya Technological University (VTU)
Address: Jnana Sangama,
VTU Main Road, Machhe,
Belgaum, Karnataka 590018
CURRENT ADDRESS: FRF2, Sai Enclave,
Ideal Homes Township,
RajaRajeshwari Nagar,
Bangalore, Karnataka 560098.
PERMANENT ADDRESS: 48, Kalyan Colony,
Barkat Nagar, Tonk Phatak,
Jaipur, Rajasthan 302015
CONTACT: +91 8792892374; HOME PHONE: +91 144-2730036
EMAIL ADDRESS: sweety2010sterster@gmail.com