Web Technology
Web Technology
In CICS, a client is the source of an external request, and the server is the CICS program that
services the request. A client can be a program on another platform that is connected to CICS over
a network, or a program on another CICS region, connected with interregional communication
(IRC).
CICS (or another product) provides a transport-specific listener (a long-running task) that starts
another task (a facilitator such as an alias or a mirror), to process the incoming request. The
facilitator uses CICS services to access the application.
A- Internet Protocols are a set of rules that governs the communication and exchange of data
over the internet. Both the sender and receiver should follow the same protocols in order to
communicate the data.
The internet and many other data networks work by organizing data into small pieces called
packets. Each large data sent between two network devices is divided into smaller packets by
the underlying hardware and software. Each network protocol defines the rules for how its
data packets must be organized in specific ways according to the protocols the network
supports.
2
Q) What is an IP Address?
A- An IP address represents an Internet Protocol address. A unique address that identifies the
device over the network. It is almost like a set of rules governing the structure of data sent over
the Internet or through a local network. An IP address helps the Internet to distinguish between
different routers, computers, and websites. It serves as a specific machine identifier in a specific
network and helps to improve visual communication between source and destination.
Types of Internet Protocol:
Internet Protocols are of different types having different uses. These are mentioned below:
1. TCP/IP (Transmission Control Protocol/ Internet Protocol)
2. SMTP (Simple Mail Transfer Protocol)
3. PPP (Point-to-Point Protocol)
4. FTP (File Transfer Protocol)
5. SFTP (Secure File Transfer Protocol)
6. HTTP (Hyper Text Transfer Protocol)
7. HTTPS (Hypertext Transfer Protocol Secure)
8. TELNET (Terminal Network)
9. POP3(Post Office Protocol 3)
10. IPv4
11. IPv6
12. ICMP
13. UDP
14. IMAP
A- The Domain Name System (DNS) is a hierarchical and distributed naming system for
computers, services, and other resources in the Internet or other Internet Protocol (IP)
networks. It associates various information with domain names (identification strings)
assigned to each of the associated entities. Most prominently, it translates readily memorized
domain names to the numerical IP addresses needed for locating and identifying computer
services and devices with the underlying network protocols. The Domain Name System has
been an essential component of the functionality of the Internet since 1985.
Q) What is HTML?
A- Hypertext Markup Language or HTML is the standard markup language for documents
designed to be displayed in a web browser. It defines the content and structure of web
content. It is often assisted by technologies such as Cascading Style Sheets (CSS) and scripting
languages such as JavaScript.
Web browsers receive HTML documents from a web server or from local storage and render
the documents into multimedia web pages. HTML describes the structure of a web page
semantically and originally included cues for its appearance.
HTML elements are the building blocks of HTML pages. With HTML constructs, images and
other objects such as interactive forms may be embedded into the rendered page. HTML
provides a means to create structured documents by denoting structural semantics for text
such as headings, paragraphs, lists, links, quotes, and other items. HTML elements are
delineated by tags, written using angle brackets. Tags such as <img> and <input> directly
introduce content into the page. Other tags such as <p> and </p> surround and provide
information about document text and may include sub-element tags. Browsers do not display
the HTML tags but use them to interpret the content of the page.
The <header> element represents a container for introductory content or a set of navigational
links. A <header> element typically contains:
HTML <body> tag defines the main content of an HTML document which displays on
the browser. It can contain text content, paragraphs, headings, images, tables, links,
videos, etc.
The <body> must be the second element after the <head> tag or it should be placed
between </head> and </html> tags. This tag is required for every HTML document and
should only use once in the whole HTML document.
Example
<!DOCTYPE html>
<html>
<head>
<title>Body Tag</title>
5
</head>
<body>
<h2>Example of body tag</h2>
<p>This paragraph is written between the body tag</p>
</body>
</html>
The id attribute is used to point to a specific style declaration in a style sheet. It is also used by
JavaScript to access and manipulate the element with the specific id.
The syntax for id is: write a hash character (#), followed by an id name. Then, define the CSS
properties within curly braces {}.
In the following example we have an <h1> element that points to the id name "myHeader".
This <h1> element will be styled according to the #myHeader style definition in the head
section:
Example
<!DOCTYPE html>
<html>
<head>
<style>
#myHeader {
background-color: lightblue;
color: black;
padding: 40px;
text-align: center;
}
</style>
</head>
<body>
</body>
</html>
Images are not technically inserted into a web page; images are linked to web pages. The <img> tag
creates a holding space for the referenced image.
6
The <img> tag is empty, it contains attributes only, and does not have a closing tag.
Syntax
To add a background image on an HTML element, use the HTML style attribute and the
CSS background-image property:
Example
Table Headers
The Headers are generally use to provide the Heading. The Table Headers can also be used to
add the heading to the Table. This contains the <th> & </th> tags.
Syntax
</th> Content...</th>
Example 1: Creating a simple table in HTML using a table tag.
<!DOCTYPE html>
<html>
<body>
<table>
<tr>
<th>Book Name</th>
<th>Author Name</th>
<th>Genre</th>
</tr>
<tr>
<td>The Book Thief</td>
<td>Markus Zusak</td>
<td>Historical Fiction</td>
</tr>
<tr>
<td>The Cruel Prince</td>
<td>Holly Black</td>
<td>Fantasy</td>
</tr>
<tr>
<td>The Silent Patient</td>
<td> Alex Michaelides</td>
<td>Psychological Fiction</td>
</tr>
</table>
</body>
</html>
The <frameset> tag in HTML is used to define the frameset. The <frameset> element contains one
or more frame elements. It is used to specify the number of rows and columns in a frameset with
their pixel of spaces. Each element can hold a separate document.
• cols: The cols attribute is used to create vertical frames in a web browser. This attribute is
basically used to define the no. of columns and their size inside the frameset tag.
• rows: The rows attribute is used to create horizontal frames in the web browser. This
attribute is used to define the no. of rows and their size inside the frameset tag.
8
• border: This attribute of frameset tag defines the width of the border of each frame in pixels.
Zero value is used for no border.
• frameborder: This attribute of frameset tag is used to specify whether a three-dimensional
border should be displayed between the frames or not for this use two values 0 and 1, where
0 defines no border and value 1 signifies for yes there will be a border.
• framespacing: This attribute of frameset tag is used to specify the amount of spacing
between the frames in a frameset. This can take any integer value as a parameter which
basically denotes the value in pixel.
HTML Forms:
HTML Forms employ the <form> element to gather input data with interactive controls. It
encompasses various input types such as text, numbers, email, password, checkboxes, radio
buttons, and submit buttons. Essentially, it’s a container for diverse input elements facilitating user
interaction.
Syntax:
<form>
<!--form elements-->
</form>
Form Elements
These are the following HTML <form> elements:
Elements Descriptions
It is used to get input data from the form in various types such as text,
<input>
password, email, etc by changing its type.
<fieldset> It is used to draw a box around other form elements and group the related data.
Elements Descriptions
In HTML forms, various input types are used to collect different types of data from users. Here are
some commonly used input types:
<input type=”text”>
<input
Defines a password field
type=”password“>
<input Allows the user to enter a number. You can specify min, max, and
type=”number“> step attributes for range.
<input
Used for checkboxes where the user can select multiple options.
type=”checkbox“>
Padding: It is the space between the element and the related content inside it. It determines how
elements look and sit within a container. It also shows the container background around the
element in it. Padding can be affected by background colors as it clears the area around the
content. To create the gap, it either grows the element size or shrinks the content inside. By
default, the size of the element increases.
Margins are used to add spaces between an image and the description of that image.
CSS Padding is used if we want to create a space between an element and the edge of the
container or the border. It is also useful in the requirement of changing the size of the element.
11
Syntax:
Selector {
property-name : /*value*/
}
You can use the CSS position property to position elements, divs, and containers in CSS according
to your needs. The great thing about the position property is that you can use it to arrange
elements of your app anywhere you want, and it's easy to learn and implement.
There are five types of positioning in CSS:
1. Static positioning
2. Relative positioning
12
3. Absolute positioning
4. Fixed positioning
5. Sticky positioning
CSS Selectors
CSS selectors are the backbone of any stylish webpage. They target HTML elements on your pages,
allowing you to add styles based on their id, class, type, attribute, and more. This guide will delve
into the intricacies of CSS selectors and their pivotal role in enhancing the aesthetics and user
experience of your web pages.
• Initialization condition: It initializes the variable and mark the start of a for loop. An
already declared variable can be used or a variable can be declared, local to loop
only.
• Test Condition: It is used for testing the exit condition of a for loop. It must return a
boolean value. It is also an Entry Control Loop as the condition is checked prior to
the execution of the loop statements.
• Statement execution: Once the condition is evaluated to be true, the statements in
the loop body are executed.
• Increment/ Decrement: It is used for updating the variable for the next iteration.
• Loop termination: When the condition becomes false, the loop terminates marking
the end of its life cycle.
• While loop starts with checking the condition. If it is evaluated to be true, then the
loop body statements are executed otherwise first statement following the loop is
executed. For this reason, it is also called the Entry control loop
• Once the condition is evaluated to be true, the statements in the loop body are
executed. Normally the statements contain an updated value for the variable being
processed for the next iteration.
• When the condition becomes false, the loop terminates which marks the end of its
life cycle.
}
while (condition);
• The do-while loop starts with the execution of the statement(s). There is no
checking of any condition for the first time.
• After the execution of the statements and update of the variable value, the
condition is checked for a true or false value. If it is evaluated to be true, the next
iteration of the loop starts.
• When the condition becomes false, the loop terminates which marks the end of its
life cycle.
• It is important to note that the do-while loop will execute its statements at least
once before any condition is checked and therefore is an example of the exit
control loop.
Objects in Javascript
Objects, in JavaScript, are the most important data type and form the building blocks for
modern JavaScript. These objects are quite different from JavaScript’s primitive data types
(Number, String, Boolean, null, undefined, and symbol) in the sense that these primitive
data types all store a single value each (depending on their types).
Syntax:
new Object(value)
Object(value)
let object_name = {
key_name: value,
...
}
programs on a computer, but provides a different set of APIs, and the DOM API is not a core
part of the Node.js runtime.
The DOM was designed to be independent of any particular programming language, making
the structural representation of the document available from a single, consistent API. Even if
most web developers will only use the DOM through JavaScript, implementations of the DOM
can be built for any language, as this Python example demonstrates:
Types of Events
Here are some common types of browser events:
• Mouse Events: Click, dblclick, mouseover, mouseout, mousedown, mouseup
• Keyboard Events: Keydown, keypress, keyup
• Form Events: Submit, change, focus, blur
• Document/Window Events: Load, resize, scroll, unload
Handling Events
When an event occurs, the browser generates an event object that describes the event and
passes it as an argument to the event handler or listener. This object contains all the relevant
information about the event, including the type of event, the target element, and other event-
specific properties.
<script>
document.getElementById('myButton').addEventListener('click', function(event) {
var eventInfo = 'Event Type: ' + event.type + '<br>Clicked Element: ' + event.target.tagName;
document.getElementById('eventInfo').innerHTML = eventInfo;
});
</script>