15 replies
  • WEB DESIGN
  • |
I got a template from the War Room and updated my new page design at Free Income at Home Course-Income From Home Course, and once everything was up, great, it looked good, however, HTML validator The W3C Markup Validation Service output resulted in like 30 errors or so, I fixed most of them and as you'll see, I only need to fix 7 more errors such as margins and background images. I been trying all kinds, but as you all know, it takes a very tiny typo to throw off the whole page into chaos.

I do have an external CSS file, http://www.earn-income-at-home.info/css/mystyles.css but can't figure out what to add in it, and what to take out in my html. Can anyone help me figure this?

Oh... I'm a complete noob in CSS:confused:

Bernard
#css
  • Profile picture of the author tonyla
    Hi,
    I ran it through this validator
    jigsaw w3 dot org
    and it came up with no errors. Can you list the error's you are getting. You should end the last rule for a given selector with a semi colon. Even though it passes one of the browsers ignores the immediate code around it.
    Tony La,
    {{ DiscussionBoard.errors[5560594].message }}
    • Profile picture of the author alcymart
      Originally Posted by tonyla View Post

      Hi,
      I ran it through this validator
      jigsaw w3 dot org
      and it came up with no errors. Can you list the error's you are getting. You should end the last rule for a given selector with a semi colon. Even though it passes one of the browsers ignores the immediate code around it.
      Tony La,
      I may have forgotten to say that I had hTML errors and not CSS, but its great to see the CSS passes... I just know things are related in my case. I did try a CSS bit for the margins html,body{margin:0;padding:0}

      but I am then left with a whitespace at the top and the bottom of the main table???As for the 2 background errors, I'm not sure what to do about those.

      Bernard
      {{ DiscussionBoard.errors[5560699].message }}
      • Profile picture of the author jumpa
        Originally Posted by alcymart View Post

        I may have forgotten to say that I had hTML errors and not CSS, but its great to see the CSS passes... I just know things are related in my case. I did try a CSS bit for the margins html,body{margin:0;padding:0}

        but I am then left with a whitespace at the top and the bottom of the main table???As for the 2 background errors, I'm not sure what to do about those.

        Bernard
        For the same problem, i usually use this :

        body{margin-top:0px;margin-right:0px;margin-left:0px;margin-bottom:0px}

        maybe this will be helpfull
        {{ DiscussionBoard.errors[5561954].message }}
        • Profile picture of the author alcymart
          Originally Posted by jumpa View Post

          For the same problem, i usually use this :

          body{margin-top:0px;margin-right:0px;margin-left:0px;margin-bottom:0px}

          maybe this will be helpfull
          Thank you, it fixed the margins, only 2 errors to go...

          Bernard
          {{ DiscussionBoard.errors[5565504].message }}
        • Profile picture of the author alcymart
          Originally Posted by jumpa View Post

          For the same problem, i usually use this :

          body{margin-top:0px;margin-right:0px;margin-left:0px;margin-bottom:0px}

          maybe this will be helpfull
          The last 2 errors I have to link the html to my external css file.

          In my html I have 2 similar errors, 1 of those is:

          <td background="images/bg-top.jpg">

          The validator doesn't like that, I need to know what to replace it with and what line to add in my css file?

          Bernard
          {{ DiscussionBoard.errors[5565881].message }}
  • Profile picture of the author ronc0011
    When ever I am working with web page design, html /CSS I do all my work in Microsoft's Visual Web Developer. This software validates all of your code on the fly as you write it. If you have a typo or if you try to use a cs class or ID that hasn't been defines it will flag that line of code in your page and tell you what the problem is. Bottom line is that when you finish a page you know that it validates because it is being checked constantly as you write it.
    {{ DiscussionBoard.errors[5562658].message }}
    • Profile picture of the author alcymart
      Originally Posted by ronc0011 View Post

      When ever I am working with web page design, html /CSS I do all my work in Microsoft's Visual Web Developer. This software validates all of your code on the fly as you write it. If you have a typo or if you try to use a cs class or ID that hasn't been defines it will flag that line of code in your page and tell you what the problem is. Bottom line is that when you finish a page you know that it validates because it is being checked constantly as you write it.

      Sounds good, I'll look into it

      Bernard
      {{ DiscussionBoard.errors[5565512].message }}
  • Profile picture of the author webpeon
    try
    <td style="background-image (images/bg-top.jpg)"></td>
    Signature
    Web 2 Mobile
    The Future of The Web
    {{ DiscussionBoard.errors[5566252].message }}
  • Profile picture of the author Istvan Horvath
    For the background issue: you will need to add a class to that td in the HTML; e.g.
    <td class="topper">

    then in the CSS:
    .topper {background: url(images/bg-top.jpg);
    background-repeat:no-repeat;}

    Invent another class name for the other bg.

    For the warning just use the 'normal' closing > instead of />.
    Signature

    {{ DiscussionBoard.errors[5566553].message }}
    • Profile picture of the author alcymart
      Originally Posted by Istvan Horvath View Post

      For the background issue: you will need to add a class to that td in the HTML; e.g.
      <td class="topper">

      then in the CSS:
      .topper {background: url(images/bg-top.jpg);
      background-repeat:no-repeat;}

      Invent another class name for the other bg.

      For the warning just use the 'normal' closing > instead of />.
      Thank you so much, I added the classes, and did as you instructed and its all good now

      Bernard
      {{ DiscussionBoard.errors[5566749].message }}
  • Profile picture of the author alcymart
    Hello Istvan, I thought everything was fixed, actually, the 2 errors were indeed fixed, and then 2 other errors popped up if you check here http://validator.w3.org/check?uri=ht...Inline&group=0

    I attempted to do what you suggested and add classes for those, but for some reason failed, could be a small mistake I made. There is a background color in the html which interferes with css I think. I have no idea, so I put backup online right after I fixed the other 2 errors per your suggestion, and I'm basically trying to do what you suggested on those other 2 backgrounds and can't get it corrected. Can you check and help? Here is my page http://www.earn-income-at-home.info and my css is here http://www.earn-income-at-home.info/css/mystyles.css

    So basically there was 4 backgrounds to fix , not just 2, its puzzling because when I ran my page in the validator the first time, it said 2 errors, after the fix, it still says 2 errors but not the same images...

    Does anybody know how to fix this?

    UPDATE: I finally narrowed it out to 1 error left to fix. I simply cannot fix this last error with the usual fix given, I tried many times and only thing I achieved was messing up my template for some unknown reason.

    I ask for help because I simply cannot fix this last issue.
    {{ DiscussionBoard.errors[5567786].message }}
  • {{ DiscussionBoard.errors[5570026].message }}
  • Profile picture of the author Istvan Horvath
    Sorry, I didn't see this last night.

    This is a typical example why the thml and css should be completely separated - if you want valid code.
    (Note: most of the IM web sites don't care at all about validation as long as it displays OK-ish in browsers...)

    To be honest, I don't really understand your preoccupation with that one error - while having a webpage "designed" with tables and full of inline style declarations inside the html code.

    If using badly templates with non-valid code - then live with it... or re-write the whole thing, including the stylesheet that has syntax error in almost every line.

    Yes, trying to "fix" something that was wrongly built from the beginning will result in new errors popping up as you progress...

    My advice? Try to set up your priorities: perfectly valid HTML/CSS code and the geeks are happy but no other advantage... or invalid code but high conversion rate of the traffic.

    If that webpage was mine, instead of obsessing with one single HTML error I'd go to the Copywriting forum and would ask for a professional review of the content (= the copy, the text) of my page. But I am aware we are all different...

    (P.S. btw, I am coming from a webdesign background and I am able to write perfectly valid html/css. However, a non-valid squeeze page of mine has been converting at 72.3% with targeted traffic. So...)
    Signature

    {{ DiscussionBoard.errors[5570239].message }}
    • Profile picture of the author alcymart
      Originally Posted by Istvan Horvath View Post

      Sorry, I didn't see this last night.

      This is a typical example why the thml and css should be completely separated - if you want valid code.
      (Note: most of the IM web sites don't care at all about validation as long as it displays OK-ish in browsers...)

      To be honest, I don't really understand your preoccupation with that one error - while having a webpage "designed" with tables and full of inline style declarations inside the html code.

      If using badly templates with non-valid code - then live with it... or re-write the whole thing, including the stylesheet that has syntax error in almost every line.

      Yes, trying to "fix" something that was wrongly built from the beginning will result in new errors popping up as you progress...

      My advice? Try to set up your priorities: perfectly valid HTML/CSS code and the geeks are happy but no other advantage... or invalid code but high conversion rate of the traffic.

      If that webpage was mine, instead of obsessing with one single HTML error I'd go to the Copywriting forum and would ask for a professional review of the content (= the copy, the text) of my page. But I am aware we are all different...

      (P.S. btw, I am coming from a webdesign background and I am able to write perfectly valid html/css. However, a non-valid squeeze page of mine has been converting at 72.3% with targeted traffic. So...)

      I fully agree with you, I just so happen to be of the perfectionist type quite simply. I know that this 1 error won't affect my business, but I do like things to be as perfect as possible especially when dealing with computer maintenance, software, or codes so to avoid further errors resulting from other errors which were not dealt with in the past.

      I thank you very much for your input Istvan, you are a great asset to our community.

      I'll still try to figure it out and if needed , correct the template itself. Thats just who I am.

      Bernard
      {{ DiscussionBoard.errors[5570483].message }}
  • Profile picture of the author alcymart
    Thank you all for your help which eventually led me to a solution. I needed to add a style in the html like so...

    style="background-image: url('images/bg.jpg');


    Bernard
    {{ DiscussionBoard.errors[5570773].message }}

Trending Topics