css

CSS: Why does reducing the font size of an adjacent inline element increase the overall leading?

I have an element that contains two span tags that each contain some text. The container element sets a font size, then the font size on the second span tag is set to a lower size. When the second span is reduced in font size, the space between the line and the next block element is increased. This occurs in both WebKit and Gecko. The p...

How do I get a <div> to always be in the top right corner of the browser window regardless of browser size?

I want the following code to always be in top right, regardless of the size (i.e. when the user resizes the browser window, it is still in the same position): <div id="navbar"><a href="#">Our Blog</a></div> The CSS that accompanies this as follows: #navbar { position: absolute; left: 850px; width: 100px; padding: 15px...

Is Creating Separate CSS Files Per Page To Speed Up Load Time Overkill?

I've been using Google PageSpeed to improve my site's performance. One of its recommendations is eliminating unused CSS in my app. Although a lot of the CSS is unused for a given page, it is used elsehwere in the app. What's the right approach here? I'm considering creating a base CSS file for common CSS and then separate files for e...

PHP Generated Inputs and Standard DOM Inputs display differently.

As you can see the following produces the exact same configuration of Select:Text:Image. However whatever the HELL I do I cannot get them to display the same without different CSS which I do not want to do. I have used CSS resets, Identical CSS, removed attributes etc. Any idea what is making them act so stupidly? It is really starting t...

The text cannot display in Print PreView

Dear all, I have a html page as below : <html> <head> <title>Print</title> <style type="text/css"> A { font-weight: normal; font-size: 10pt; text-decoration: none; } </style> <link rel="stylesheet" type="text/css" hr...

Browser not displaying XML with CSS properly when XML has a PHP extension.

I'm using a PHP file to output an XML Document. I'm using a CSS file to format that XML Document. My browser (Safari) won't show the formatting unless I feed it a file with an xml extension. I thought the header took precedence over the extension. parser.php (after php processing) <?xml version="1.0" encoding="ISO-8859-1"?> <?xml-st...

Is it possible to upload Vignette files directly, without using the web interface?

In the project I'm working on, we have web resource files (e.g. JS, CSS, images, etc) stored in Vignette. As a web developer I find this cumbersome to work with, since I frequently update these files, and since each upload of a file requires several clicks and waiting for up to 5 seconds on each click. It would be awesome if I could in...

Hiding and showing HTML elements with javascript

I'm having trouble showing and hiding a tag on my page. When the page loads I have <a id="mylink" class="hiddenClass">...</a> hiddenClass has display: none When a certain event occurs, I use javascript to try and show the element in block style document.getElementById("mylink").display = "block"; It doesn't show it. When I aler...

How do I keep an image in the center of the page regardless of browser window size?

I want to do this using only CSS + HTML. It has to work in all major/latest browsers - not IE 6 just yet. The code I have is as follows: <div id="left_arrow"> <img src="images/left-arrow.png"> </div> #left_arrow { position: absolute; left: 0px; margin: 10px 0 15px 0; /* top, right, bottom, left */ ...

how can I print a web page with all its css style attached to the page?

I want to add a print button to enable users to print my web page. However when I print all the css styles are lost. It seems the printer only keeps the basic html elements. If I also want to print out the page exactly as it looks like in a browser, what should I do? I mean if I use a color printer it will print a colorful page with css ...

box turn effect

I want to implement box turn effect as in the following site when mouseover (please see the boxes below animation) http://pepsi.com/ It is made using flash,but i want to develop it using other than flash. will it be possible? ...

How do I select only two of three imgs within the same div using jQuery?

The code is as follows: <div id="compv-navbar"> <a href="#"><img src="image1.png" id="icon1"></a> | <a href="#"><img src="image2.png" id="icon2"></a> | <a href="#"><img src="image3.png" id="icon3"></a> | <span id="view_name"> 2-up</span> </div> The jQuery is as follows: $("#icon2") ....

How to rotate an image using client side solution

I am wondering if there is any way to dynamically rotate an image or invert an image using a client side solution? I don't care if it is plain old javascript, jquery plugin, css. I just wondered if there was some way to do this dynamically on the client side rather than having to write server side code to do for each image which I can do...

Do you know a css framework like Clever CSS?

I found some time ago a CSS framework like Clever CSS but I don't remember its name and I can't find it now. Do you know CSS Frameworks like Clever CSS? It was like Clever CSS, but more powerful. Thanks. EDIT: I have just realized it is actually a css preprocessor, it is like Less CSS too. ...

IE7 puts absolutely positioned div underneath, ignores z-index

Have tried to fix this on my own and so far failed. The yellow auto-completion divs that show up as you start typing in the subject or location field appears below the other text in IE7. This is the website: http://www.universitytutor.com Setting a higher Z-index didn't fix it. Works in all other browsers (IE8, FF, Chrome, Safari) b...

A div should always be 100% height - either viewport or content. Followed examples online and still stuck!

I have viewed the source of this page and applied it to my page. In FireFox and Safari, I can't for the life of me get the main container to be the height of the viewport. There is always an ugly margin down the bottom. I have inspected all I can with Firebug, which seems to tell me that neither html, body or #mainContainer have the co...

How to overlap one image over another?

in my application I am displaying thumbnails of user album's images.What I want to do is to display a delete image button over the right corner of the album image.When user clicks on the delete image it will pass the image id and delete the image info from database.My problem is how to overlap delete image on the album image? delete imag...

styling input type checkbox

how can i style <input type="checkbox"> tags? i need to change border type and color... Thanks a lot ...

How to make a component to use a specific css when both id and class is set

I have a component (say a div) where I had set style for both the id and class. I have to use the specific styles (id or class) depending upon the event, which I guess can be done by JavaScript. Is this possible? Please help!!! ...

Colorbox shows under flash

I am using jQuery's colorbox to open up an iframe on a page. On the page there are two flash SWFs. When I click the button that opens the colorbox, those flash SWFs appear over the top of my colorbox div. I've checked the CSS properties of the colorbox, and the overlay has position:absolute and z-index:999. I have given the SWFs a z-inde...