Zaloguj | Zarejestruj | FAQ
Anonymous

<!DOCTYPE html>

+ Odpowiedz

Posty: 4 Strona 1 z 1


<!DOCTYPE html>

przez pavz » So gru 17, 2011 10:17 pm

what is <!DOCTYPE html> it doesn't say in all of tutorials and i really want to know can someone please tell me,
Avatar użytkownika

pavz

  • Posty: 5
  • Dołączył(a): Śr paź 26, 2011 9:01 pm

Re: <!DOCTYPE html>

przez Edward123 » N gru 18, 2011 2:51 am

<!DOCTYPE html>

This is simply the Doctype for HTML5 which is the latest version of html.. But not all browsers are up to date with the latest HTML5 applications.

The Doctype does not validate your JavaScript.

Edward123
Avatar użytkownika

Edward123

  • Posty: 89
  • Dołączył(a): Śr paź 05, 2011 7:57 pm

Re: <!DOCTYPE html>

przez chrisf1288 » N gru 18, 2011 3:06 am

Yupp. The doctype tells the browser what markup language the code is written in. It is needed for your website to be validated correctly. In previous versions of HTML, your doctype would look something like this:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


But now in HTML5 its just <!DOCTYPE html>!!!
Avatar użytkownika

chrisf1288

  • Posty: 128
  • Dołączył(a): N cze 26, 2011 1:01 am

Re: <!DOCTYPE html>

przez atik » N gru 18, 2011 8:27 am

Hi pavz,
As wikipedia says about doctype
A Document Type Declaration, or DOCTYPE, is an instruction that associates a particular SGML or XML document (for example, a webpage) with a Document Type Definition (DTD) (for example, the formal definition of a particular version of HTML). In the serialized form of the document, it manifests as a short string of markup that conforms to a particular syntax.

For more info on doctype you can visit w3school,
HTML <!DOCTYPE> Declaration
HTML5 <!DOCTYPE> Declaration
Avatar użytkownika

atik

  • Posty: 471
  • Dołączył(a): Pn paź 17, 2011 4:55 pm

Re: <!DOCTYPE html>

przez pavz » N gru 18, 2011 12:06 pm

thanks guys!
Avatar użytkownika

pavz

  • Posty: 5
  • Dołączył(a): Śr paź 26, 2011 9:01 pm


+ Odpowiedz

Strona 1 z 1