How to style CSS role

Tags: css

Problem :

In the following HTML

<div id="content" role="main">

the id can be accessed through #content in CSS. How do I access role="main".

Solution :

Use CSS attribute selectors:



    CSS Howto..

    How can i perform a smooth css transition to my sticky bar?

    How to change link color when using jquery mouseover

    How to rotate multiple words with CSS?

    JavaScript / Jquery : How to find line-through words

    How to know values of all attributes and properties of a tag element in HTML

    How do you create a webpage with a floating image, top left, bottom right, and with wrapping text in the middle

    How to organize html and css to do this UI design with responsive design

    CSS How to align checkbox image

    How do I get responsive images to stay equivalent heights as they scale?

    How to make sure items are added to the end of a moving list?

    How to change placeholder color on focus?

    how to animate “simple jquery filtering” by using css only

    How to animate a ball travelling pre-defined paths in HTML5, Javascript and CSS?

    Test if is visible with ng-show attribute

    How to get height of CSS manipulated image?

    Fancyselect: How to force to open the selector at the bottom?

    How to keep css background image blurred inside a container?

    Gulp : How to copy multiple files and keep the folder structure

    What do i need and how do I start to adjust the css of a website with “encrypted” .gz files

    How to style OL number points in CSS [duplicate]

    How to center HTML content

    How to hide Fileupload with simple span by using css

    How can I target a element inside h2

    How to use pseudo-class :target within an image map

    How to improve the way I use Textmate for Ruby on Rails, HTML, CSS and Javascript?

    Prestashop - How to edit views [closed]

    How to apply different css style to gwt datagrid widget in the same page? [duplicate]

    How To Change Text Box Content On Hover

    How to make a collapsible with a single css drop shadow in Jquery mobile?

    CSS : How to remove margin between