---
title: "Hur sätter jag rätt DocType på XHTML Strict?"
type: "forum-thread"
url: "https://www.webforum.nu/amne/html-css/70566-hur-sätter-jag-rätt-doctype-på-xhtml-strict"
topic: "HTML & CSS"
topic_url: "https://www.webforum.nu/amne/html-css"
author: "trexter"
published: "2003-03-09T17:45:08.000Z"
updated: "2003-03-09T19:39:58.000Z"
replies: 7
views: 382
page: 1
pages: 1
language: "sv-SE"
site: "webForum — webforum.nu"
rights: "Upphovsrätten till varje inlägg tillhör dess författare."
attribution: "Citera som: webForum, https://www.webforum.nu/amne/html-css/70566-hur-sätter-jag-rätt-doctype-på-xhtml-strict"
---

# Hur sätter jag rätt DocType på XHTML Strict?

## #1 — trexter, 2003-03-09T17:45Z

Jag använder följande:
\<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"\>

men sidan går inte genom validiatorn.
"I was not able to extract a character encoding labeling from any of the valid sources for such information. Without encoding information it is impossible to validate the document."

 :)

Permalänk: https://www.webforum.nu/p/70566

## #2 — elvelind, 2003-03-09T17:48Z

doctypen är helt rätt.
sätt character encoding med en meta tagg.
\<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /\>

Permalänk: https://www.webforum.nu/p/974137

## #3 — trexter, 2003-03-09T17:50Z

Merci!

  :D

Permalänk: https://www.webforum.nu/p/974138

## #4 — trexter, 2003-03-09T17:56Z

Hmm...
jag är total nybörjare på XHTML och undrar varför den säger att \</head\> inte är avslutad.

"Line 7, column 6: end tag for "head" which is not finished (explain...)."

 :)

Permalänk: https://www.webforum.nu/p/974142

## #5 — trexter, 2003-03-09T18:04Z

Ok, det berodde tydligen på att jag inte hade någon title.

 :)

Permalänk: https://www.webforum.nu/p/974146

## #6 — trexter, 2003-03-09T18:07Z

Hmm... hur har de tänkt sig att man ska använda länkar med variabler?

```
Line 10, column 41: cannot generate system identifier for general entity "strCategoryName" 
  ...ref="productList.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärba
                                          ^
Line 10, column 41: general entity "strCategoryName" not defined and no default entity (explain...). 
  ...ref="productList.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärba
                                          ^
Line 10, column 56: reference not terminated by REFC delimiter 
  ...t.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärbara datorer</a> 
                                          ^
Line 10, column 56: reference to external entity in attribute value 
  ...t.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärbara datorer</a> 
                                          ^
Line 10, column 56: reference to entity "strCategoryName" for which no system identifier could be generated 
  ...t.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärbara datorer</a> 
                                          ^
Line 10, column 40: entity was defined here 
  <a href="productList.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärb
```

 :)

Permalänk: https://www.webforum.nu/p/974148

## #7 — mikkeX, 2003-03-09T18:37Z

Ersätt & med &amp;amp;.

Permalänk: https://www.webforum.nu/p/974163

## #8 — dectgap, 2003-03-09T19:39Z

> **trexter skrev:**
>
> Hmm... hur har de tänkt sig att man ska använda länkar med variabler?
> 
>
>
> ```
> Line 10, column 41: cannot generate system identifier for general entity "strCategoryName" 
>   ...ref="productList.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärba
>                                           ^
> Line 10, column 41: general entity "strCategoryName" not defined and no default entity (explain...). 
>   ...ref="productList.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärba
>                                           ^
> Line 10, column 56: reference not terminated by REFC delimiter 
>   ...t.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärbara datorer</a> 
>                                           ^
> Line 10, column 56: reference to external entity in attribute value 
>   ...t.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärbara datorer</a> 
>                                           ^
> Line 10, column 56: reference to entity "strCategoryName" for which no system identifier could be generated 
>   ...t.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärbara datorer</a> 
>                                           ^
> Line 10, column 40: entity was defined here 
>   <a href="productList.asp?intCategoryID=2&strCategoryName=Bärbara datorer">Bärb
> ```
>
> 
> 
>  :)

Tänk på att du inte får ha mellanslag i en url. Ersätt dem med "%20".

Permalänk: https://www.webforum.nu/p/974202

---

Tråden på webben: https://www.webforum.nu/amne/html-css/70566-hur-sätter-jag-rätt-doctype-på-xhtml-strict
