Communiquez avec les autres et partagez vos connaissances professionnelles

Inscrivez-vous ou connectez-vous pour rejoindre votre communauté professionnelle.

Suivre

Can you please explain what are DocType and Charset in HTML5?

user-image
Question ajoutée par Yasmeen Husam , Web Developer , Al Fahid Systems
Date de publication: 2019/04/07
Muhammad  Faisal
par Muhammad Faisal , Teacher , Skill Development council lahore

Yeah! its very basic Question. The docType in HTML is declaration is used to inform a website visitor's browser that the document being rendered is an HTML document. <!DOCTYPE html> is doctypeof html 5. And the CharSet in HTML is specifies the character encoding used in the style sheet

Mohammed Abdellatif Abdelrahman Mohammed
par Mohammed Abdellatif Abdelrahman Mohammed , Supervisor Team , Dpromix Campany

HTML 4.01 doesn't specify the use of the charset attribute with the meta element, but any recent major browser will still detect it and use it, even if the page is declared to be HTML4 rather than HTML5. ... You do not need to use the XML declaration, since the file is being served as HTML

محمد عيد سيد احمد خليل
par محمد عيد سيد احمد خليل , Senior web developer , العرض المتقن 2P

Doctypes tell the browser in what language the page is written in, be it HTML or XHTML.

Charset is a method of converting bytes into characters. To validate or display an HTML document, a program must choose a character encoding. HTML 5 authors have three means of setting the character encoding 

PRAMODA SWAMI HM
par PRAMODA SWAMI HM , CLIENT RELATIONSHIP OFFICER , Today Centrum direct ltd

The declaration is used to inform a website visitor's browser that the document being rendered is an HTML document. is doctype of html 5. @charset specifies the character encoding used in the style sheet, and specifies the encoding for the HTML document

More Questions Like This