Java Script

Java Script

JavaScript is a lightweight, cross-platform, single-threaded, and interpreted compiled programming language. It is also known as the scripting language for webpages. It is well-known for the development of web pages, and many non-browser environments also use it.

JavaScript is a weakly typed language (dynamically typed). JavaScript can be used for Client-side developments as well as Server-side developments. JavaScript is both an imperative and declarative type of language. JavaScript contains a standard library of objects, like Array, Date, and Math, and a core set of language elements like operators, control structures, and statements.

Client-side

It supplies objects to control a browser and its Document Object Model (DOM). Like if client-side extensions allow an application to place elements on an HTML form and respond to user events such as mouse clicks, form input, and page navigation. Useful libraries for the client side are AngularJS, ReactJS, VueJS, and so many others.

Server-side

It supplies objects relevant to running JavaScript on a server. For if the server-side extensions allow an application to communicate with a database, and provide continuity of information from one invocation to another of the application, or perform file manipulations on a server. The useful framework which is the most famous these days is node.js.

Imperative language

In this type of language we are mostly concerned about how it is to be done. It simply controls the flow of computation. The procedural programming approach, object, oriented approach comes under this as async await we are thinking about what is to be done further after the async call.

Declarative programming

In this type of language we are concerned about how it is to be done, basically here logical computation requires. Her main goal is to describe the desired result without direct dictation on how to get it as the arrow function does.

CSS

CSS

CSS (Cascading Style Sheets) is a language designed to simplify the process of making web pages presentable. It allows you to apply styles to HTML documents, describing how a webpage should look by prescribing colors, fonts, spacing, and positioning. CSS provides developers and designers with powerful control over the presentation of HTML elements.

HTML uses tags and CSS uses rulesets. CSS styles are applied to the HTML element using selectors. CSS is easy to learn and understand, but it provides powerful control over the presentation of an HTML document.

HTML

HTML

HTML, or HyperText Markup Language, is the standard markup language used to create web pages. It’s a combination of Hypertext, which defines the link between web pages, and Markup language, which is used to define the text document within tags to structure web pages. This language is used to annotate text so that machines can understand and manipulate it accordingly. HTML is human-readable and uses tags to define what manipulation has to be done on the text. This guide will help you understand the workings of HTML and explain it with examples.

Overview:

  • Hypertext: Refers to the way in which webpages are linked to one another through hyperlinks. This allows users to navigate between different pages on the web.
  • Markup Language: A language that uses tags to annotate the content within a document. In HTML, these tags define the structure and presentation of text, images, and other media on a webpage.

Basic Structure of an HTML Document:

				
					<!DOCTYPE html>
<html>
<head>
    <title>Page Title</title>
</head>
<body>
    <h1>This is a Heading</h1>
    <p>This is a paragraph.</p>
    <a href="https://www.example.com" target="_blank" rel="noopener">This is a link</a>
</body>
</html>

				
			

Key Components:

  1. Tags and Elements:

    • Tags: Enclosed in angle brackets, e.g., <h1>, <p>, <a>. Most tags have an opening and a closing tag, like <p> and </p>.
    • Elements: The combination of a tag, its content, and the closing tag. For example, <h1>This is a Heading</h1> is an element.
  2. Attributes:

    • Tags can have attributes that provide additional information. Attributes are written inside the opening tag, such as href in an anchor tag (<a>).
    • Example: <img src="image.jpg" alt="Description of image">
  3. Head Section (<head>):

    • Contains metadata, such as the title of the page (<title>), links to CSS files, and other information not directly displayed on the page.
  4. Body Section (<body>):

    • Contains the content that will be visible to the user, including text, images, videos, links, and more.

What Is HTML?

HTML stands for Hyper text Markup Language and it is used to create website. It uses HTML tags and attributes to describe the structure and formatting of a web page.

HTML consists of various elements, that are responsible for telling search engines how to display page content. For example, headings, lists, images, links, and more.

HTML consists of a series of elements, represented by tags (<>), which wrap around content to define its purpose. These elements can include:

1. Headings (h1-h6)
2. Paragraphs (p)
3. Links (a)
4. Images (img)
5. Lists (ul, ol, li)
6. Forms (form, input, textarea)
7. Tables (table, tr, td)
8. Divisions (div)
9. Spans (span)

HTML documents typically include:

1. A doctype declaration (!DOCTYPE html)
2. A head section (head) containing metadata
3. A body section (body) containing the visible content

Key Components of HTML:

  1. Tags: HTML uses tags to structure content. Tags are enclosed in angle brackets, such as <tagname>. Most tags come in pairs, with an opening tag (e.g., <p>) and a closing tag (e.g., </p>).
  2. Elements: An HTML element consists of the opening tag, the content, and the closing tag. For example:
				
					<p>This is a paragraph.</p>
				
			

In this example, <p> is the tag, and the entire structure forms a paragraph element.

3.Attributes: Tags can have attributes that provide additional information about an element. Attributes are included within the opening tag and are usually written in name-value pairs. For example:

				
					<a href="https://www.example.com" target="_blank" rel="noopener">Visit Example</a>
				
			

Here, href is an attribute that specifies the link destination.

4. Document Structure: A basic HTML document has a standard structure, including the <!DOCTYPE html> declaration, <html>, <head>, and <body> elements. For example:

				
					<!DOCTYPE html>
<html>
<head>
    <title>Page Title</title>
</head>
<body>
    <h1>My First Heading</h1>
    <p>My first paragraph.</p>
</body>
</html>
				
			
  • <!DOCTYPE html> declares the document type.
  • <html> is the root element.
  • <head> contains meta-information like the title and links to stylesheets.
  • <body> contains the content of the webpage that is visible to users.