O'Reilly logo

Mastering HTML5 Forms by Gaurav Gupta

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Guidelines

In this section, we will see the CSS3 guidelines for effective styling of the forms.

Some of the best practices for CSS3 are as follows:

  • Avoid using inline styling for CSS. External CSS files must be used for styling.
  • Minified CSS files must be used wherever possible as this a practice for removing unnecessary characters from the code to reduce the size.
  • Use combined files for CSS.
  • Avoid use of multiple declarations wherever possible.
  • Always think of progressive enhancement.
  • Vendor prefixes should be organized and well commented.
  • For background-related properties use fallback.
  • The readability of the text should not be affected while using typography.
  • Enable the fallback and test the form in every browser.
  • Try to use efficient CSS selectors.
  • Avoid ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required