Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [css][html] Zgodność z validatorem
poxrimex
post
Post #1





Grupa: Zarejestrowani
Postów: 368
Pomógł: 2
Dołączył: 23.09.2007

Ostrzeżenie: (60%)
XXX--


Walidator w3 wywala błąd gdy w tym skrypcie przycisk jest jeszcze w znacznikach <form>, lecz gdy jest po </form> to już wszystko wporządku:

Oto błąd:

Line 38, Column 117: document type does not allow element "input" here; missing one of "p", "h1", "h2", "h3", "h4", "h5", "h6", "div", "pre", "address", "fieldset", "ins", "del" start-tag.
…px; height: 25px; margin-top: 5px;" />



The mentioned element is not allowed to appear in the context in which you've placed it; the other mentioned elements are the only ones that are both allowed there and can contain the element mentioned. This might mean that you need a containing element, or possibly that you've forgotten to close a previous element.

One possible cause for this message is that you have attempted to put a block-level element (such as "<p>" or "<table>") inside an inline element (such as "<a>", "<span>", or "<font>").

Ten post edytował poxrimex 12.03.2008, 15:07:15


--------------------



Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 4)
conix
post
Post #2





Grupa: Zarejestrowani
Postów: 136
Pomógł: 0
Dołączył: 8.02.2008

Ostrzeżenie: (0%)
-----


Powodem jest <p>" or "<table> w <a>", "<span>", lub "<font>"
PS. Daj linie bledu...

Ten post edytował conix 12.03.2008, 15:16:17


--------------------
Jeśli pomogłem kliknij na Pomógł
Jeśli nie pomogłem kliknij na Pomógł
Go to the top of the page
+Quote Post
poxrimex
post
Post #3





Grupa: Zarejestrowani
Postów: 368
Pomógł: 2
Dołączył: 23.09.2007

Ostrzeżenie: (60%)
XXX--


dla tej wersji kodowej:

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">


i tego kodu:

  1. <form action="zaloguj.php" method="post" style="display: inline">
  2. <input type="image" src="guj.gif" alt="zarejestruj" />
  3. </form>


validator wywala

Line 15, Column 65: document type does not allow element "input" here; missing one of "p", "h1", "h2", "h3", "h4", "h5", "h6", "div", "pre", "address", "fieldset", "ins", "del" start-tag.
…image" src="guj.gif" alt="zarejestruj" />



The mentioned element is not allowed to appear in the context in which you've placed it; the other mentioned elements are the only ones that are both allowed there and can contain the element mentioned. This might mean that you need a containing element, or possibly that you've forgotten to close a previous element.

One possible cause for this message is that you have attempted to put a block-level element (such as "<p>" or "<table>") inside an inline element (such as "<a>", "<span>", or "<font>").


--------------------



Go to the top of the page
+Quote Post
grzesiek_g
post
Post #4





Grupa: Zarejestrowani
Postów: 249
Pomógł: 30
Dołączył: 18.07.2007

Ostrzeżenie: (0%)
-----


W XHTML 1.0 Strict element formularza jakim jest input MUSI być zamknięty w innym znaczniku. Jakim? Walidator już Ci odpowiedział.


--------------------
Warsztat: Ubuntu 12.10, PHPStorm
http://vertoo.pl
Go to the top of the page
+Quote Post
poxrimex
post
Post #5





Grupa: Zarejestrowani
Postów: 368
Pomógł: 2
Dołączył: 23.09.2007

Ostrzeżenie: (60%)
XXX--


no fakt działa już ;]


--------------------



Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 19.08.2025 - 13:13