• Resolved dcthree

    (@dcthree)


    Hello,

    I have spent hours trying desperately to solve this XHTML discrepency and would love a hand if anyone can spare the time.

    I am relatively new to XHTML so please just state the obvious if I am simply stupid! : )

    I have two main errors that I am getting when validating; the errors are shown subsequent to each piece of code below: the site is http://www.dcthree.co.uk (view it in firefox as I have not edited for I.E. yet)

    (If you go to the W3C validation service: <ahref=”http://validator.w3.org/”&gt; you can view the errors when typing in my url: http://www.dcthree.co.uk)

    1) #page { background: url("http://www.dcthree.co.uk/wp-content/themes/DCThree The # is the error here

    2) </style> The > is the error here

    I have in total 29 errors although 90% of them are simply for < or > if anyone knows how to fix these plese let me know as I fear I won’t have any hair left in 24hrs!

    Many thanks,

    Nick

Viewing 5 replies - 1 through 5 (of 5 total)
  • Your style tag is wrong:

    <style type="text/css" media="screen"/>

    You’ve closed it. It should be:

    <style type="text/css" media="screen">

    However, fixing that doesn’t fix your errors – now I see 44 errors. 🙁

    Thread Starter dcthree

    (@dcthree)

    okay… thats weird…

    I had 29 errors and proceeded to take out the forward slash and now I have 44… LOVELY! : )

    Thanks so much for trying ma city sista! lol… I really appreciate it!

    Does anybody else have the faintest idea whats going wrong here!

    The code that RoseCitySister tried to fix is from my header.php:

    `<style type=”text/css” media=”screen”>

    <?php
    // Checks to see whether it needs a sidebar or not
    if ( !empty($withcomments) && !is_single() ) {
    ?>

    <?php } else { // No sidebar ?>
    #page { background: url(“<?php bloginfo(‘stylesheet_directory’); ?>/images/dcthreebgwide.jpg”) repeat-y top; border: none; }
    <?php } ?>

    </style>`

    I have been playing around with it all night/morning and still cant fix the error on this line…

    <style type="text/css" media="screen">

    The > symbol is the error…

    Pleeeease help,

    Many thanks again,

    Nick

    Thread Starter dcthree

    (@dcthree)

    Hahaha… obviously a forum professional too… lol… the boxes were supposed to be around the code : )

    Thats how much I need HELP!! lol : )

    Current validation errors.

    You can’t put a style block in the body of the page – it needs to be in the head section.

    Also, there’s no such element as an h9. 🙂

    There are several other basic validation errors here that I’d suggest you squash – especially if you’re offering web design and SEO.

    IMO, you should be very comfortable figuring out what you can, and can’t, do in code and how to troubleshoot your own errors if you’re offering these services to customers.

    Hope that helps.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘XHTML Validation Help’ is closed to new replies.