css

A tension between DRY and performance?

I have a number of pages in my app that are showing partial FOUCs (flashes of unstyled content) upon loading, which occurs because some of them have stylesheets and/or javascript defined at the head of the document rather than in the layout. The fundamental issue is that the DOM is firing before these stylesheets are loaded. In order to...

Control Layout Template

I need a way to layout controls in a page. Let me ask you by example. I have four different action buttons (Edit, Delete, etc..) that do the same actions on any page, but sometimes I want them laid out horizontally and some other times vertically, depending on which page is displaying them. So I thought of placing all four buttons in a u...

Display color picture as monochrome

Is there a way to display a color picture as greyscale using Html/Css? Ie. no server side processing. Edited: monochrome -> greyscale ...

Horizontal Scrollbar when reducing browser window

Good day, I've been doing some modifications to this website and the owner wants to have a horizontal scroll bar appearing when the browser window is reduced to a size that is smaller than the 'container' of the website. Right now it doesnt appear. I think that my main CSS is responsible for this. This CSS has overflow-x:hidden; and...

making a div extend all the way down to the bottom of the page

Hi There, My website has varaible content length, and this sometime means that the footer does not site at the bottom of the page, is there a way to make the footer fill whatever space is left? http://www.ibdnetwork.co.uk/members-content/forums ...

overflow:auto does not work in ff 3.5.13

<html xmlns="http://www.w3.org/1999/xhtml"&gt; <head> <title></title> <script type="text/javascript" src="../../Scripts/jquery-1.4.1.js"></script> <style type="text/css"> table { border: solid 1px #e8eef4; border-collapse: collapse; } table td { padding: 5px; border: solid 1px ...

Dropdown menu not showing right

Hello, my problem is that when I try to show my dropdown menu under "Departamentos" its kinda to the left... not in the right position under Departamentos... I try for hours but nothing, What could be the problem?? LINK TO THE WEBSITE ...

When to use <br> line breaks vs CSS positioning?

I've often wondered about the proper use of a <br> line break. Seems that often they are incorrectly used for positioning or clearing content where CSS should instead be used. W3schoools.org says to use <br> for blank lines, but not for creating or separating paragraphs. Looking over W3C HTML5 spec draft, it's a little clearer that...

Giving table rows a solid, continuous background color

Hello, I am using a table with 1 column and three rows. I would like to give all 3 rows a solid, continuous background color. How could I do this? Thanks in advance, John echo "<table class=\"samplesrec\">"; echo '<tr class="class2">'; echo '<td class="sitename1"></td>'; echo '</tr>'; echo '<tr>'; ...

Window.open as modal popup?

I want open window.open as modal popup. var features = 'resizable= yes; status= no; scroll= no; help= no; center= yes; width=460;height=140;menubar=no;directories=no;location=no;modal=yes'; window.open(href, 'name', features, false); I can use Window.ShowModelDialog(), but in my child window I am calling parent javascript metho...

When I add a margin to a nested DIV, it causes the parent DIV to receive the margin instead, unless I give the parent DIV a border. Why?

Has anyone else ever ran across this? This is the second time it's come up in as many years and I am not sure the "correct" way to solve it. I can achieve the same results with padding in the child, but it just makes no sense. Testing in Safari/FF. ...

JQuery Scrollable Missing position onload and on api seek in webkit browsers

Hiya All, Strange issue i am having while working on this in the bottom right hand corner is a history section with a scrollable section that moved right or left. On load it picks a random number and moves to it. Problem is that on load (without moving) it loads in the wrong position, and on moving with the api it moves to the wrong of...

I imported a jQuery plugin into my project and my <a> tag CSS is overriding its <a> tag CSS

I have a page that uses certain styles that I have defined. On the same page I just imported an external jQuery plugin that uses its own styles, including, for example, an <a> tag style that is being overridden by my own. How do I ensure that the styles in my stylesheet do not override the styles in the stylesheet of the jQuery plugin?...

How do I get IE to properly reposition an element after a sibling resizes vertically?

I have the following markup: <nav id='tab_links'> <a href='#view1'>One</a> <a href='#view2'>Two</a> </nav> <div id='container'> <div id='view1'>Short Content</div> <div id='view2'>Much longer content</div> </div> <footer> <input type='submit' /> </footer> and the following styles: #view2 { display: none; } #footer { display:...

browser compatiable question?

i have this css box(div) that on mozilla firefox displays in the middle of the browser, but on the IE, it floats to the left, could you tell me what the issue is? #div-regForm,.registered{ border:3px solid #eeeeee; padding:15px; background:white; color:black; margin:30px auto 40px auto; width:600px; } html: <...

How do I change an elements class in jquery?

Assuming I have <ul class="myList verticalList"> how can I change the value of verticalList using jquery? ...

jQuery search results ... hover and click no longer working?

So I created a couple of functions for my search autocomplete results (custom autocomplete) and while the results were static, the hover and click events worked fine... but now that the results are dynamically being generated, my divs no longer respond to their hover and click events. Is jQuery not seeing the divs anymore because they'...

HTML/CSS input/textarea, default text, and colors

Two semi-related questions: 1) I've seen <input> and <textarea> boxes that contain some default text, like "enter search terms here", and the moment you click on the box, the text disappears. How is this implemented? Is this a Javascript thing? 2) Can the default text be in one color, and whatever you type (either overwriting, or appen...

CSS layout acting very weird and not positioning the elements where it should.

The elements aren't positioning themselves as I want them to. I want the picture to be 20px away from the left, why is the logos div so thin? :S Also why is the topuserbar div going under? There seems to be no reason. Here is the CSS and HTML. It's not rocket science, so that's extra frustrating because it shouldn't be rendering like t...

What's the support for .className.andClassName in the current browsers?

Confusing title? Sure! In CSS, you can specify: .button.blue { ... } Which will target elements that have both class names. Does anyone know what the browser support is? ...