Computer Science, asked by minagajraj26782, 11 months ago

explain basic HTML tag​

Answers

Answered by Alyrock007
7

Answer:

</p><p>\huge \red ANSWER:---

An HTML tag is a special word or letter surrounded by angle brackets, < and >. You use tags to create HTML elements , such as paragraphs or links. Many elements have an opening tag and a closing tag — for example, a p (paragraph) element has a <p> tag, followed by the paragraph text, followed by a closing </p> tag.

Answered by ankityadav24
2

Explanation:

An HTML element is an individual component of an HTML (Hypertext Markup Language) document or web page.[vague] HTML is composed of a tree of HTML nodes, such as text nodes. Each node can have HTML attributes specified. Nodes can also have content, including other nodes and text. Many HTML nodes represent semantics, or meaning. For example, the <title> node represents the title of the document.

Concepts Edit

Document vs. DOM Edit

HTML documents are delivered as "documents".[note 1] These are then parsed, which turns them into the Document Object Model (DOM) internal representation, within the web browser.[note 2][note 3] Presentation by the web browser (such as screen rendering or access by JavaScript) is then performed on this internal DOM, not the original document.

Early HTML documents (and to a lesser extent today's HTML documents) were largely invalid HTML and riddled with syntax errors. The parsing process was also required to "fix" these errors as best it could. The result was often not correct (i.e., it did not represent what a careless coder had originally intended) but was at least valid according to the HTML standard. Only in the rarest cases would the parser abandon parsing altogether.

Elements vs. tags Edit

As is generally understood, the position of an element is indicated as spanning from a start tag, possibly including some child content, and is terminated by an end tag.[3] This is the case for many, but not all, elements within an HTML document.

As HTML (before HTML5) is based on SGML,[4] its parsing also depends on the Document Type Definition (DTD), specifically an HTML DTD (e.g. HTML 4.01[5][note 4]). The DTD specifies which element types are possible (i.e. it defines the set of element types) and also the valid combinations in which they may appear in a document. It is part of general SGML behavior that, where only one valid structure is possible (per the DTD), its explicit statement in any given document is not generally required. As a simple example, the <p> tag indicating the start of a paragraph element should be complemented by a </p> tag indicating its end. But since the DTD states that paragraph elements cannot be nested, an HTML document fragment <p>Para 1 <p>Para 2 <p>Para 3is thus inferred to be equivalent to <p>Para 1 </p><p>Para 2 </p><p>Para 3. (If one paragraph element cannot contain another, any currently open paragraph must be closed before starting another.) Because this implication is based on the combination of the DTD and the individual document, it is not usually possible to infer elements from document tags alone but only by using an SGML—or HTML—aware parser with knowledge of the DTD. HTML5 creates a similar result by defining what tags can be omitted.[6]

SGML vs. XML Edit

SGML is complex, which has limited its widespread understanding and adoption. XML was developed as a simpler alternative. Although both can use the DTD to specify the supported elements and their permitted combinations as document structure, XML parsing is simpler. The relation from tags to elements is always that of parsing the actual tags included in the document, without the implied closures that are part of SGML.[note 5]

HTML as used on the current web is likely to be either treated as XML, by being XHTML, or as HTML5; in either case the parsing of document tags into DOM elements is simplified compared to legacy HTML systems. Once the DOM of elements is obtained, behavior at higher levels of interface (example: screen rendering) is identical or nearly so.[note 6]

%block; vs. box Edit

Part of this CSS presentation behavior is the notion of the "box model". This is applied to those elements that CSS considers to be "block" elements, set through the CSS display: block; declaration.

HTML also has a similar concept, although different, and the two are very frequently confused. %block; and %inline; are groups within the HTML DTD that group elements as being either "block-level" or "inline".[8] This is used to define their nesting behavior: block-level elements cannot be placed into an inline context.[note 7] This behavior cannot be changed; it is fixed in the DTD. Block and inline elements have the appropriate and different CSS behaviors attached to them by default,[8] including the relevance of the box model for particular element types.

Note though that this CSS behavior can, and frequently is, changed from the default. Lists with <ul><li> ... are %block; elements and are presented as block elements by default. However, it is quite common to set these with CSS to display as an inline list.

hope it helps you dear

mark as brainlist plzzzzzz

Similar questions