Professional Documents
Culture Documents
IT
IT
computers and a computer network or data network is a telecommunications network that allows
computers to exchange data. The physical connection between networked computing devices is
established using either cable media or wireless media. The best-known computer network is the
Internet.
Networking engineering is a complicated task, which involves software, firmware, chip level
engineering, hardware, and electric pulses. To ease network engineering, the whole networking
concept is divided into multiple layers. Each layer is involved in some particular task and is
independent of all other layers. But as a whole, almost all networking tasks depend on all of these
layers. Layers share data between them and they depend on each other only to take input and send
output.
1. Layered Tasks : In layered architecture of Network Model, one whole network process is
divided into small tasks. Each small task is then assigned
to a particular layer which works dedicatedly to process
the task only. Every layer does only specific work.
In layered communication system, one layer of a host deals
with the task done by or to be done by its peer layer at
the same level on the remote host. The task is either
initiated by layer at the lowest level or at the top most
level. If the task is initiated by the-top most layer, it is
passed on to the layer below it for further processing.
The lower layer does the same thing, it processes the
task and passes on to lower layer. If the task is initiated by lower most layer, then the reverse path
is taken.
2. OSI Model : Open System Interconnect is an open standard for all communication systems.
OSI model is established by International Standard Organization (ISO). This model
has seven layers:
Presentation Layer: This layer defines how data in the native format
of remote host should be presented in the native format of host.
Network Layer: This layer is responsible for address assignment and uniquely
addressing hosts in a network.
Data Link Layer: This layer is responsible for reading and writing data from and onto
the line. Link errors are detected at this layer.
Physical Layer: This layer defines the hardware, cabling wiring, power output, pulse
rate etc.
3. Internet Model : Internet uses TCP/IP protocol suite, also known as Internet suite. This
defines Internet Model which contains four layered architecture. OSI Model is general
communication model but Internet Model is what the internet uses for all its communication. The
internet is independent of its underlying network architecture so is its Model. This model has the
following layers:
Link Layer: This layer provides mechanism of sending and receiving actual data.
Switching is process to forward packets coming in from one port to a port leading towards
the destination. In a telecommunications network, a switch is a device that channels incoming data
from any of multiple input ports to the specific output port that will take the data toward its
intended destination. When data comes on a port it is called ingress, and when data leaves a port or
goes out it is called egress. A communication system may include number of switches and nodes. At
broad level, switching can be divided into two major categories:
1. Circuit Switching : When two nodes communicate with each other over a dedicated
communication path, it is called circuit switching. There is a need of pre-specified route from which
data will travels and no other data is permitted. In circuit switching, to transfer the data, circuit
must be established so that the data transfer can take place. Circuit switching was designed for
voice applications. Telephone is the best suitable example of circuit switching. Before a user can
make a call, a virtual path between caller and callee is established over the network.
2. Message Switching : This technique was somewhere in middle of circuit switching and packet
switching. In message switching, the whole
message is treated as a data unit and is
switching / transferred in its entirety.
A switch working on message switching, first
receives the whole message and buffers it
until there are resources available to
transfer it to the next hop. If the next hop
is not having enough resource to
accommodate large size message, the
message is stored and switch waits.
Remote login : uses simple desktop sharing software to give you a "remote control" for
accessing your computer -- and all of its software and hard drive files -- from any Internet-connected
device anywhere in the world.
Remote login works exactly the same way as desktop sharing. In desktop sharing, there are two
separate parties: the host computer and the remote user. To share a desktop, the host computer
allows a remote user to view the contents of the host computer's desktop over the Internet. The
host computer can also hand over keyboard and mouse controls to the remote user. With remote
log-in, your home or work computer is the host and you (in this case) are the remote user.
1. Software download
2. Internet connection
3. Secure desktop sharing network
For remote login to work, both the host computer and all remote users have to download and install
the same desktop sharing software. Remote login will only work if the host computer is powered
on, connected to the Internet and running the desktop sharing software. Each time you open and
run the desktop sharing software on the host computer, the software starts a new session. Each
session has a particular ID and/or password that's required to remotely log in to the host
computer. Once the session has been established, most desktop sharing software quietly runs in
the background of the host computer until a remote login request is made.
Frames: HTML frames are used to divide your browser window into multiple sections where
each section can load a separate HTML document. A collection of frames in the browser window is
known as a frameset. The window is divided into frames in a similar way the tables are organized:
into rows and columns.
Creating Frames
To use frames on a page we use <frameset> tag instead of <body> tag. The <frameset> tag defines,
how to divide the window into frames. The rows attribute of <frameset> tag defines horizontal
frames and cols attribute defines vertical frames. Each frame is indicated by <frame> tag and it
defines which HTML document shall open into the frame.
Example : <html>
<head>
<title>HTML Frames</title>
</head>
<noframes>
</noframes>
</frameset>
</html>
<frameset>Attribute & Description
cols : Specifies how many columns are contained in the frameset and the size of each column. You can
specify the width of each column in following ways −
Absolute values in pixels. For example, to create three vertical frames, use cols = "100, 500, 100".
A percentage of the browser window. For example, to create three vertical frames, use cols = "10%, 80%,
10%".
rows : This attribute works just like the cols attribute and takes the same values, but it is used to specify
the rows in the frameset. For example, to create two horizontal frames, use rows = "10%, 90%". You can
specify the height of each row in the same way as explained above for columns.
border : This attribute specifies the width of the border of each frame in pixels. For example, border =
"5". A value of zero means no border.
frameborder : This attribute specifies whether a three-dimensional border should be displayed between
frames. This attribute takes value either 1 (yes) or 0 (no). For example frameborder = "0" specifies no
border.
framespacing : This attribute specifies the amount of space between frames in a frameset. This can take
any integer value. For example framespacing = "10" means there should be 10 pixels spacing between
each frames.
src :This attribute is used to give the file name that should be loaded in the frame. Its value can be any URL.
For example, src = "/html/top_frame.htm" will load an HTML file available in html directory.
name : This attribute allows you to give a name to a frame. It is used to indicate which frame a document
should be loaded into. This is especially important when you want to create links in one frame that load pages
into an another frame, in which case the second frame needs a name to identify itself as the target of the link.
marginwidth : This attribute allows you to specify the width of the space between the left and right of the
frame's borders and the frame's content. The value is given in pixels. For example marginwidth = "10".
marginheight : This attribute allows you to specify the height of the space between the top and bottom of the
frame's borders and its contents. The value is given in pixels. For example marginheight = "10".
scrolling : This attribute controls the appearance of the scrollbars that appear on the frame. This takes values
either "yes", "no" or "auto". For example scrolling = "no" means it should not have scroll bars.
HTML Helpers (Plug-ins) : Helper applications (plug-ins) are computer programs that extend
the standard functionality of a web browser.
Plug-ins can be added to web pages with the <object> tag or the <embed> tag.
Plug-ins can be used for many purposes: display maps, scan for viruses, verify your bank id, etc.
It is used to embed plug-ins (like Java applets, PDF readers, Flash Players) in web pages.
Example
<object data="audi.jpeg"></object>
DHTML : DHTML stands for Dynamic HTML. DHTML is NOT a language or a web standard.
DHTML is a TERM used to describe the technologies used to make web pages dynamic and
interactive. To most people DHTML means the combination of HTML, JavaScript, DOM, and CSS.
Dynamic HTML, or DHTML, is an umbrella term for a collection of technologies used together to
create interactive and animated web sites by using a combination of a static markup language
(such as HTML), a client-side scripting language (such as JavaScript), a presentation definition
language (such as CSS), and the programming interface through which a page's code can be
changed. (such as Document Object Model). DHTML allows scripting languages to change
variables in a web page's definition language, which in turn affects the look and function of
otherwise "static" HTML page content, after the page has been fully loaded and during the
viewing process. Thus the dynamic characteristic of DHTML is the way it functions while a page is
viewed, not in its ability to generate a unique page with each page load. By contrast, a dynamic
web page is a broader concept — any web page generated differently for each user, load
occurrence, or specific variable values. This includes pages created by client-side scripting, and
ones created by server-side scripting (such as PHP, Perl, JSP or ASP.NET) where the web server
generates content before sending it to the client.
DHTML Technologies
With DHTML a Web developer can control how to display and position HTML elements in a
browser window. HTML 4.0 , Cascading Style Sheets (CSS) , Document Object Model , JavaScript
(and VBScript)
JavaScript also defines two trivial data types, null and undefined, each of which defines only a
single value. In addition to these primitive data types, JavaScript supports a composite data type
known as object
JavaScript Variables : Variables can be thought of as named containers. You can place data
into these containers and then refer to the data simply by naming the container.
Before you use a variable in a JavaScript program, you must declare it. Variables are declared
with the var keyword as follows.
<script type="text/javascript">
<!--
//-->
</script>
<script type="text/javascript">
<!--
var money;
money = 2000.50;
//-->
</script>
Expressions : An expression is any valid set of literals, variables, operators, and expressions
that evaluates to a single value. The value may be a number, a string, or a logical value.
Conceptually, there are two types of expressions: those that assign a value to a variable, and those
that simply have a value. For example, the expression
x=7
is an expression that assigns x the value 7. This expression itself evaluates to 7. Such expressions
use assignment operators. On the other hand, the expression
3+4
simply evaluates to 7; it does not perform an assignment. The operators used in such expressions
are referred to simply as operators.
<html>
<body>
<script type="text/javascript">
document.write("a + b = ");
result = a + b;
document.write(result);
document.write(linebreak);
document.write("a - b = ");
result = a - b;
document.write(result);
document.write(linebreak);
document.write("a / b = ");
result = a / b;
document.write(result);
document.write(linebreak);
document.write("a % b = ");
result = a % b;
document.write(result);
document.write(linebreak);
document.write("a + b + c = ");
result = a + b + c;
document.write(result);
document.write(linebreak);
a = ++a;
document.write("++a = ");
result = ++a;
document.write(result);
document.write(linebreak);
b = --b;
document.write("--b = ");
result = --b;
document.write(result);
document.write(linebreak);
</script>
</body>
</html>
typeof Operator : The typeof operator is a unary operator that is placed before its single
operand, which can be of any type. Its value is a string indicating the data type of the operand.
The typeof operator evaluates to "number", "string", or "boolean" if its operand is a number,
string, or boolean value and returns true or false based on the evaluation.
This statement tells the browser to write "Hello Dolly." inside an HTML element with id="demo":
Most JavaScript programs contain many JavaScript statements. The statements are executed, one
by one, in the same order as they are written.
var x, y, z;
x = 5;
y = 6;
z = x + y;
document.getElementById("demo").innerHTML = z;
JavaScript - Functions : A function is a group of reusable code which can be called anywhere
in your program. This eliminates the need of writing the same code again and again. It helps
programmers in writing modular codes. Functions allow a programmer to divide a big program into
a number of small and manageable functions.
Syntax Example
<script type="text/javascript"> <script type="text/javascript">
<!-- <!--
function functionname(parameter-list) function sayHello()
{ {
statements alert("Hello there");
} }
//--> //-->
</script> </script>
All JavaScript values, except primitives(A primitive value is a value that has no properties or methods.),
are objects. JavaScript defines 5 types of primitive data types: string , number , boolean , null ,
undefined.
Objects can contain many values. The values are written as name : value pairs (name and value
separated by a colon).
With JavaScript, you can define and create your own objects.
The String object lets you work with a series of characters; it wraps Javascript's string
primitive data type with a number of helper methods.
As JavaScript automatically converts between string primitives and String objects, you can call any of
the helper methods of the String object on a string primitive.
Syntax
charAt()
concat()
indexOf()
Returns the index within the calling String object of the first occurrence of the specified value, or -1 if not
found.
lastIndexOf()
Returns the index within the calling String object of the last occurrence of the specified value, or -1 if not
found.
substr()
Returns the characters in a string beginning at the specified location through the specified number of
characters.
toLowerCase()
toString()
toUpperCase()
valueOf()
The Array object lets you store multiple values in a single variable. It stores a fixed-size
sequential collection of elements of the same type. An array is used to store a collection of data, but
it is often more useful to think of an array as a collection of variables of the same type.
Syntax
concat()
Returns a new array comprised of this array joined with other array(s) and/or value(s).
every()
Returns true if every element in this array satisfies the provided testing function.
forEach()
indexOf()
Returns the first (least) index of an element within the array equal to the specified value, or -1 if none is
found.
join()
pop()
Removes the last element from an array and returns that element.
push()
Adds one or more elements to the end of an array and returns the new length of the array.
sort()
// named
var Rectangle = class Rectangle {
constructor(height, width) {
this.height = height;
this.width = width;
}
};
JS classes : Classes are in fact "special functions", and just as you can define function
expressions and function declarations, the class syntax has two components: class expressions and class
declarations.
jQuery is a fast, lightweight, and feature-rich JavaScript library that is based on the priciple "write
less, do more". It's easy-to-use APIs makes the things like HTML document traversal and
manipulation, event handling, adding animation effects to a web page much simpler that works
seamlessly across all the major browsers. jQuery also gives you the ability to create an Ajax based
application in a quick and simple way.
Cookies are data, stored in small text files, on your computer. When a web server has sent a
web page to a browser, the connection is shut down, and the server forgets everything about the
user. Cookies were invented to solve the problem "how to remember information about the user":
When a user visits a web page, his name can be stored in a cookie.
Next time the user visits the page, the cookie "remembers" his name.
document.cookie = "username=John Doe";
var x = document.cookie;
CGI : The Common Gateway Interface, or CGI, is a set of standards that define how information is
exchanged between the web server and a custom script. CGI, is a standard for external gateway
programs to interface with information servers such as HTTP servers.
To understand the concept of CGI, lets see what happens when we click a hyper link to browse a
particular web page or URL.
1. Your browser contacts the HTTP web server and demand for the URL ie. filename.
2. Web Server will parse the URL and will look for the filename in if it finds that file then sends back to
the browser otherwise sends an error message indicating that you have requested a wrong file.
3. Web browser takes response from web server and displays either the received file or error message.
However, it is possible to set up the HTTP server so that whenever a file in a certain directory is
requested that file is not sent back; instead it is executed as a program, and whatever that program
outputs is sent back for your browser to display. This function is called the Common Gateway
Interface or CGI and the programs are called CGI scripts. These CGI programs can be a PERL Script,
Shell Script, C or C++ program etc.
Ajax uses XHTML for content, CSS for presentation, along with Document Object Model and
JavaScript for dynamic content display.
AJAX is a web browser technology independent of web server software.
A user can continue to use the application while the client program requests information from the
server in the background. With AJAX, when you hit submit, JavaScript will make a request to the
server, interpret the results, and update the current screen. In the purest sense, the user would
never know that anything was even transmitted to the server.
or simply
pattern − A string that specifies the pattern of the regular expression or another regular
expression.
attributes − An optional string containing any of the "g", "i", and "m" attributes that specify global,
case-insensitive, and multiline matches, respectively.