homepage Welcome to WebmasterWorld Guest from 54.167.173.250
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Visit PubCon.com
Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
Please help wiith an error in W3C validation
Attribute "BORDER" is not a valid attribute. Did you mean "border"?
nubbin




msg:3891052
 8:03 pm on Apr 12, 2009 (gmt 0)

I am getting this error when validating my home page:

Attribute "BORDER" is not a valid attribute. Did you mean "border"?

I am not sure how to fix this and would appreciate some help. The line of code cuasing the error is:

The line of code the error is on is:
<td align="center" class="boxText"><form name="quick_find" action="http://widget.com/advanced_search_result.php" method="get"><input type="text" name="keywords" size="30" maxlength="30" style="width: 120px">&nbsp;<input type="image" src="includes/languages/english/images/buttons/button_quick_find.gif" border="0" alt="Search" title=" Search "><br><br><a href="http://widget.com/advanced_search.php"><b>Advanced Search</b></a></form></td>

Thanks

 

rocknbil




msg:3891054
 8:09 pm on Apr 12, 2009 (gmt 0)

Attribute "BORDER" is not a valid attribute. Did you mean "border"?

Are you sure that's the line? Because I don't see border in caps. This *sounds* like you're trying to validate a 4.01 strict or XHTML doctype and attributes need to be in lower case, but I don't see that in your snippet.

Receptional Andy




msg:3891058
 8:17 pm on Apr 12, 2009 (gmt 0)

I think it's because you've set a border for an <input>, which is not a valid attribute for that element (see Forms in HTML documents [w3.org]). Try using CSS like style="border:0;" instead of border="0". Likely, you will also need to remove the "alt" attribute.

[edited by: Receptional_Andy at 8:18 pm (utc) on April 12, 2009]

nubbin




msg:3891217
 3:03 am on Apr 13, 2009 (gmt 0)

Thanks for your help. I followed Receptional Andy's advice and that has fixed it and my page now passes W3C validation.

encyclo




msg:3891327
 12:04 pm on Apr 13, 2009 (gmt 0)

Are you sure that's the line? Because I don't see border in caps.

This is one of the current version of the W3C validator's "helpful" error messages, which simply aren't helpful when trying to validate HTML4.

The validator serves the same error message when validating HTML or XHTML, however the the Did you mean "border" message is only relevant in XHTML. The WDG validator [htmlhelp.com] is an alternative that is worth trying.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved