css

CSS Tidy configuration

I am using CSS Tidy. Due to all of its compression measures, in some cases it's messing up my pages by combining or re-arranging selectors, etc. Even with the options shown below, pages with the compressed CSS do not render as they do with the uncompressed. My question is: How can I configure CSS Tidy to combine all of my CSS files into...

Firefox doesn't take table styling from master style?

I have a stylesheet in my master page that defines several general things (basic doc structure, header images, control styling etc). Amongs those styling rules are the table stylings. Now in all pages that inherit from the master page, the tables are styled the same. It works in Opera and it even works in IE. But WHY oh WHY doesn't it w...

CSS3 selector to find the 2nd div of the same class

I need a CSS selector that can find the 2nd div of 2 that has the same class. I've looked at nth-child() but it's not what I want since I can't see a way to further clarify what class I want. These 2 divs will be siblings in the document if that helps. My HTML looks something like this: <div class="foo">...</div> <div class="bar">...</...

How to align checkboxes and their labels consistently cross-browsers

This is one of the minor CSS problems that plagues me constantly. How do folks around StackOverflow vertically align checkboxes and their labels consistently cross-browser? Whenever I align them right in Safari (usually using vertical-align: baseline on the input), they're completely off in Firefox and IE. Fix it in Firefox, and Safar...

Fluid CSS layout and Borders

In designing a fluid layout, how do you use borders without ruining the layout. More specifically, I have a HTML widget which consists of five divs. I would like the five divs to take up all the room in the containing element. I would also like to have a 1px border around each. I tried: .box { float: left; height: 100%; width: 100%; ...

css overflow in a:hover tag

I have an image(a map) with some points of interest placed using position: absolute and the coordinates of each poi. I want it to expand the info of each POI on mouseover using: .poi a { width: 32px; height: 32px; overflow: hidden } .poi a:hover { width: 128px; height: 192px; overflow: auto } This works fine ...

Checkbox size

Is it possible to set the size of a checkbox using css or html ? "width" and "size" work under IE6+ but not with firefox, where the checkbox stays 16x16 even if I set a smaller size ...

Keeping content in two table columns stuck to the roof of the respective table column

Hello, When using tables in a CSS-based layout, I've noticed if I have a table with 4 columns (2 on the side are small for spacing, 2 in the middle are for content), when I type content in one of the two middle columns, it will stay at the top, which is perfect. However, if I type content in the other middle column, and press enter, th...

IE does not render <A> tag properly

SOLVED: Nevermind, the links were visited, and the border definition was missing for visited links (as someone pointed out, thanks). As for the color being first place in the border definition, the snippet comes from the IE Developper Toolbar, this is not directly my code. Anyway, thank you guys ! Why does the link in the following snip...

jQuery draggable table elements

jQuery's draggable functionality doesn't seem to work on tables (in FF3 or Safari). It's kind of difficult to envision how this would work, so it's not really surprising that it doesn't. <html> <style type='text/css'> div.table { display: table; } div.row { display: table-row; } div.cell { display: table-cell; } </style>...

jQuery Graceful Degradation

I want to spruce up some areas of my website with a few jQuery animations here and there, and I'm looking to replace my AJAX code entirely since my existing code is having some cross-browser compatibility issues. However, since jQuery is a JavaScript library, I'm worried about my pages not functioning correctly when JavaScript is turned ...

Preventing Screen burn

I've written a helpdesk monitor application that is designed to sit on a big plasma screen in a support department, the application has 5 views that it revolves around, the content of most of those screens is different, but they have some common components, being one silverlight control and a css background image. I'm worried that over ...

Float a div right, without impacting on design.

Hi, I want to float a div to the right at the top of my page. It contains a 50px square image, but currently it impacts on the layout of the top 50px on the page. Currently its: <div style="float: right;"> ... </div> I tried z-index as I thought that would be the answer, but I couldn't get it going. I know it's something simple ...

ASP.NET GridView CSS issue when sorting turned on

I created a GridView in an ASP.NET application and used the Auto Format tool to apply an attractive style. Now I'm moving the style markup to the CSS sheet and I'm having a weird problem where the text in the header row isn't the correct color (it should be white but it shows up a bright blue). This problem only shows up when I turn so...

How do you create a toggle button?

I want to create a toggle button in html using css. I want it so that when you click on it , it stays pushed in and than when you click it on it again it pops out. If theres no way of doing it just using css. Is there a way to do it using jQuery? ...

Fade Background Color on Update Panel

I have a radajaxpanel that is populated with the selected item from a combobox on another update panel. Currently the radajaxpanel is the same background color as the rest of the page. What I'd like to do, is based on it being populated with data, change it's background color to a muted red. I want it to stand out as an action that ha...

CSS block elements on a line

What's the most common way to deal with a series of block elements that need to be on a line (if javascript needs to be able to modify their widths, for example)? What are the pros and cons to applying float:left to each of them vs. using positioning to place them? ...

CSS Conventions / Code Layout Models

Has there been any attempt and creating a formalized method for organizing CSS code? Before I go and make up my own strategy for keeping things readable, I'm wondering what else is out there. Goggle hasn't been very helpful, as I'm not entirely sure what terms to search for. I'm thinking more along the lines of indenting/spacing, when ...

Unordered lists and accessability

Many (most?) sites aiming for accessability and standards compliance use unordered lists for their navigation. Does this make the site more accessible or does it just provide useful elements for styling? I don't mind them, and I have been using unordered lists in this way. It's just that, when I remove the styling from a page to try to ...

Best approach for styling navigation using unordered lists in ASP.NET

In ASP.NET (not MVC), what is the best approach to programmatically setting styles on an unordered list used for navigation so the appropriate menu item is styled as the active item if that page is being viewed? This would most likely be used in conjunction with a MasterPage. ...