SitePoint Sponsor

User Tag List

Results 1 to 6 of 6

Hybrid View

  1. #1
    SitePoint Enthusiast
    Join Date
    Apr 2002
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Valadate, says Error in Code, help.

    I am trying to validate some code, and I keep getting this error can someone help?

    Here is the code:

    <BODY BGCOLOR="#FFFFFF" ONLOAD="preloadImages();" TOPMARGIN="0" MARGINHEIGHT="0" LEFTMARGIN="0" MARGINWIDTH="0" LINK="#003366" VLINK="#660066" BACKGROUND="images/bkgd.gif">

    Here are the errors I am getting from a valdating prg:

    Error: unsupported attribute "marginheight" for tag <body>
    Error: unsupported attribute "topmargin" for tag <body>

    Can someone help?

  2. #2
    SitePoint Evangelist
    Join Date
    Jan 2002
    Posts
    420
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Those margins arent supported for html4.

    Use CSS instead to define the margins - not sure if it works in netscape 4 tho
    Wavelan

  3. #3
    What? Maelstrom's Avatar
    Join Date
    Oct 2001
    Location
    Whistler BC originally from Guelph Ontario
    Posts
    2,175
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Don't use any body tags

    <style type="text/css">
    body
    {
    margin:0;
    background-image: url;
    background-color:#ffffff;
    }
    a
    {
    color:#003366;
    }
    a:link
    {
    color:#660066;
    }
    <style>

    That should validate fine...
    Maelstrom Personal - Apparition Visions
    Development - PhP || Mysql || Zend || Devshed
    Unix - FreeBSD || FreeBsdForums || Man Pages
    They made me a sitepoint Mentor - Feel free to PM me or Email me and I will see if I can help.

  4. #4
    SitePoint Wizard
    Join Date
    Oct 2001
    Location
    Tucson, Arizona
    Posts
    1,858
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally posted by Maelstrom
    Don't use any body tags
    You mean to use only the <body> tag. If there was no <body> tag, your page surely wouldn't validate.

  5. #5
    SitePoint Wizard silver trophy redemption's Avatar
    Join Date
    Sep 2001
    Location
    Singapore
    Posts
    5,269
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    he probably meant body attributes right Maelstrom?

  6. #6
    What? Maelstrom's Avatar
    Join Date
    Oct 2001
    Location
    Whistler BC originally from Guelph Ontario
    Posts
    2,175
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yes I did mean attributes. Oops. Sorry bout that...

    BTW Redemtion no need to respond twice, I understood the first time
    Maelstrom Personal - Apparition Visions
    Development - PhP || Mysql || Zend || Devshed
    Unix - FreeBSD || FreeBsdForums || Man Pages
    They made me a sitepoint Mentor - Feel free to PM me or Email me and I will see if I can help.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •