1

I ran my mobile home page through the website validator at: https://validator.w3.org/

and it complains that:

The CSS style sheet contains rules referencing the position, display or float properties

Support for CSS style sheets varies from one device to the other, and cannot be entirely relied upon, especially to position the elements precisely. Floating and absolutely positioned elements should also be avoided on limited screens for usability reason since they may trigger scrolling in two directions.

Under more information, it states:

Best practice: Organize documents so that if necessary they may be read without style sheets.

To me, a solution is to use a two-column table for layout but I keep reading that tables are only meant to be used for tabular content.

I happen to use css float for adsense to blend the ad in with the content.

I can't make the ad take up the entire width of the screen as that pushes content down the fold.

Now my question is, is W3C being stupid with me, or should I just forget using floats and use table cells?

  • which site is it? So can take a look? – Abu Nooh Jan 10 '16 at 20:08
  • thenew-mobile.clubcatcher.com – Mike Jan 10 '16 at 20:17
  • @Mike: I don’t see this message when validating that URL in validator.w3.org (which redirects to validator.w3.org/nu because you use HTML5). – unor Jan 10 '16 at 20:34
  • go to: validator.w3.org/mobile and put my site in there and you'll see. – Mike Jan 10 '16 at 20:55
  • 1
    Click more information... Nothing is complaining.... its a caution, not a error. It's merely stating that you should be aware that older devices may not support the usage of floats... however... these are very old devices! Not even Google, Microsoft and other sites visited in the billions cares about these eon old devices, nor should you, unless your targetting a 3rd world country. – Simon Hayter Jan 10 '16 at 21:00
2

The W3C mobile validator reports errrors, cautions and informational based results. It's extremely likely and common for websites to have cautions. When W3C reports a caution it does not mean your site is broken.

Break down of result types:

  • Critical Error(s): X
  • Severe Error(s): -
  • Medium Error(s): ...
  • Low Error(s): .
  • Caution(s): !
  • Informational: ?

Frankly trying to cater for very old devices will ultimately dampen user experience thats why the likes of most websites do not.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.