How to make a div 100% height of the browser window

There are a couple of CSS 3 measurement units called: Viewport-Percentage (or Viewport-Relative) Lengths What are Viewport-Percentage Lengths? From the linked W3 Candidate Recommendation above: The viewport-percentage lengths are relative to the size of the initial containing block. When the height or width of the initial containing block is changed, they are scaled accordingly. These … Read more

How can I transition height: 0; to height: auto; using CSS?

Use max-height in the transition and not height. And set a value on max-height to something bigger than your box will ever get. See JSFiddle demo provided by Chris Jordan in another answer here. #menu #list { max-height: 0; transition: max-height 0.15s ease-out; overflow: hidden; background: #d5d5d5; } #menu:hover #list { max-height: 500px; transition: max-height … Read more

I need an unordered list without any bullets

You can remove bullets by setting the list-style-type to none on the CSS for the parent element (typically a <ul>), for example: ul { list-style-type: none; } You might also want to add padding: 0 and margin: 0 to that if you want to remove indentation as well. See Listutorial for a great walkthrough of … Read more

Is it possible to apply CSS to half of a character?

Now on GitHub as a Plugin! Feel free to fork and improve. Demo | Download Zip | Half-Style.com (Redirects to GitHub) Pure CSS for a Single Character JavaScript used for automation across text or multiple characters Preserves Text Accessibility for screen readers for the blind or visually impaired Part 1: Basic Solution Demo: http://jsfiddle.net/arbel/pd9yB/1694/ This … Read more

How do I disable the resizable property of a textarea?

The following CSS rule disables resizing behavior for textarea elements: textarea { resize: none; } To disable it for some (but not all) textareas, there are a couple of options. You can use class attribute in your tag(<textarea class=”textarea1″>): .textarea1 { resize: none; } To disable a specific textarea with the name attribute set to … Read more

Set cellpadding and cellspacing in CSS?

Basics For controlling “cellpadding” in CSS, you can simply use padding on table cells. E.g. for 10px of “cellpadding”: td { padding: 10px; } For “cellspacing”, you can apply the border-spacing CSS property to your table. E.g. for 10px of “cellspacing”: table { border-spacing: 10px; border-collapse: separate; } This property will even allow separate horizontal … Read more

Is there a CSS parent selector?

There is currently no way to select the parent of an element in CSS, at least not a way that works across all browsers. If there was a way to do it, it would be in either of the current CSS selectors specs: Selectors Level 3 Spec CSS 2.1 Selectors Spec That said, the Selectors … Read more