Rezultate 1 la 6 din 6

Subiect: Css Validation

  1. #1
    Avatarul lui Stelian
    Stelian este deconectat Membru SeoPedia
    Reputatie:
    37
    Data înscrierii
    6th February 2006
    Locaţie
    Bucuresti
    Vârstă
    43
    Posturi
    331
    Putere Rep
    37


    Implicit

    Astazi, toata ziua, m-am chuinit sa corectez in jur de 300 de erori. Am doborat cam 150. M-am blocat si imi vine sa renunt.
    http://validator.w3.org/check?uri=http%3A%...buzaulive.ro%2F
    Error Line 63 column 8: ID "headermenu" already defined.
    Error Line 64 column 8: ID "headermenu" already defined.
    Error Line 65 column 8: ID "headermenu" already defined.
    ...........................
    Cod:
    <table>
    <tr>
    <td id="headermenu" bgcolor="#A5D72F" width="20%"><a href="url">FORUM</a></td>
    <td id="headermenu" bgcolor="#32D387" width="20%"><a href="url">POZE</a></td>
    <td id="headermenu" bgcolor="#31D5D0" width="20%"><a href="url">ANUNTURI1</a></td>
    <td id="headermenu" bgcolor="#3AA4CB" width="20%"><a href="url">ANUNTURI2</a></td>
    <td id="headermenu" bgcolor="#3986C4" width="20%"><a href="url">CHAT</a></td>
    </tr>
    <tr>
    <td id="headermenu" bgcolor="#C7E680" width="20%" style="height:7px;"></td>
    <td id="headermenu" bgcolor="#5ADC9E" width="20%" style="height:7px;"></td>
    <td id="headermenu" bgcolor="#4EDCBC" width="20%" style="height:7px;"></td>
    <td id="headermenu" bgcolor="#6CBBD9" width="20%" style="height:7px;"></td>
    <td id="headermenu" bgcolor="#478EC9" width="20%" style="height:7px;"></td>
    </tr>
    </table>
    Google nu m-a prea ajutat.
    L-am sucit pe toate partile.
    1. In loc de id am pus class (asa era sugerat) dar nu-mi mai apar chenarele asa cum ar trebui iar textul nu se mai formateaza.
    2. Am pus headermenu1, headermenu2, headermenu3 .......... si in .css le-am definit ca si pe headermenu. Efectul, la fel ca la pct1.
    3. Diferite combinatii care imi trec de validare, dar nu imi mai afiseaza corect chenarele :p.

    Are careva vreo sugestie?
    Are vreun rost sa-mi mai sparg capul cu asa ceva?

    Va multumesc.

  2. #2
    Avatarul lui necropsique
    necropsique este deconectat Ambasador
    Reputatie:
    39
    Data înscrierii
    28th June 2005
    Locaţie
    Iasi
    Vârstă
    45
    Posturi
    374
    Putere Rep
    39


    Implicit

    CSS Classes vs ID

    The W3C defines class ID as "a unique identifier to an element"
    Standards specify that any given id name can only be referenced once within a page or document. From our experience, IDs are most commonly used correctly in CSS layouts. This makes sense because there are usually only one menu per page, one banner, and usually only one content pane.

    Vezi poate ai uitat atunci cand ai pus in loc de id class, sa modifici in fisierul .css din #headermenu in .headermenu. Nu ar trebui sa aibe nici o importanta daca sunt clase sau id-uri.


    In fine, succes.

    p.s.: de ce nu bagi width="20%" si height:7px; direct in id-ul sau clasa din fisierul .css ?

  3. #3
    Avatarul lui Kul
    Kul
    Kul este deconectat Membru SeoPedia
    Reputatie:
    38
    Data înscrierii
    16th July 2005
    Locaţie
    Constanta
    Vârstă
    47
    Posturi
    47
    Putere Rep
    38


    Implicit

    pai XHTML 1.0 Transitional la atatea tabele... tie iti trebuie HTML 4.01 Transitional acolo. XHTML-ul este destul de restrictiv, de aici si erorile acelea.

    basca:
    <tag id="id_unic_in_toata_pagina" ...
    <tag name="nume_pe_care_il_pot_folosi_si_in_alta_parte_ in_pagina" ...


    ID "headermenu" already defined
    , normal nu?

  4. #4
    Avatarul lui Stelian
    Stelian este deconectat Membru SeoPedia
    Reputatie:
    37
    Data înscrierii
    6th February 2006
    Locaţie
    Bucuresti
    Vârstă
    43
    Posturi
    331
    Putere Rep
    37


    Implicit

    kul, da, normal
    necropsique, punctu era de vina . Merci mult. Am reusit sa scap de toate, mai putin de prima problema.
    Error Line 49 column 87: there is no attribute "onMouseOver".

    ...e="Utilizator" size="12" onMouseOver="this.focus(); onfocus="if(this.value ==

    You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).

    This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.

    How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute.
    Cod:
    &#60;form action=&#34;user.php&#34; method=&#34;post&#34; style=&#34;margin&#58;0px;&#34;&#62;
    	Utilizator   &#60;input type=&#34;text&#34; name=&#34;uname&#34; value=&#34;Utilizator&#34; size=&#34;12&#34; onMouseOver=&#34;this.focus&#40;&#41;; onfocus=&#34;if&#40;this.value == &#39;Utilizator&#39;&#41; this.value = &#39;&#39;;&#34; style=&#34;font-size&#58;11px; padding&#58;0px;&#34;&#34; /&#62;
    	Parola   &#60;input type=&#34;password&#34; name=&#34;pass&#34; value=&#34;*****&#34; size=&#34;12&#34; onMouseOver=&#34;this.focus&#40;&#41;;&#34; onfocus=&#34;if&#40;this.value == &#39;*****&#39;&#41; this.value = &#39;&#39;;&#34; style=&#34;font-size&#58;10px; padding&#58;0px;&#34; /&#62;
    	&#60;input type=&#34;hidden&#34; name=&#34;op&#34; value=&#34;login&#34; /&#62; 
    	&#60;input type=&#34;submit&#34; value=&#34;ok&#34; /&#62;
    	&#60;/form&#62;
    Pot folosi o alta metoda?
    Tinand cont ca o mai am doar pe-asta, nu mai renunt. Thanks again.

  5. #5
    Avatarul lui Razvan Pop
    Razvan Pop este deconectat Membru SeoPedia
    Reputatie:
    43
    Data înscrierii
    9th July 2004
    Locaţie
    Bucuresti
    Vârstă
    45
    Posturi
    1.376
    Putere Rep
    43


    Implicit

    Stelian,

    Ia incearca onmouseover in loc de onMouseOver, cu lowercase.
    Cu stima,
    Razvan Pop

  6. #6
    Avatarul lui Stelian
    Stelian este deconectat Membru SeoPedia
    Reputatie:
    37
    Data înscrierii
    6th February 2006
    Locaţie
    Bucuresti
    Vârstă
    43
    Posturi
    331
    Putere Rep
    37


    Implicit

    Razvan, merge. Stiu ca am incercat si azi-noapte, ca doar imi era sugerat acolo, dar cred ca din cauza oboselii am omis ceva.


    Multumesc mult.

Informații subiect

Utilizatori care navighează în acest subiect

Momentan este/sunt 1 utilizator(i) care navighează în acest subiect. (0 membrii și 1 vizitatori)

Permisiuni postare

  • Nu puteţi posta subiecte noi.
  • Nu puteţi răspunde la subiecte
  • Nu puteţi adăuga ataşamente
  • Nu puteţi modifica posturile proprii
  •