css-background-image

JQuery in Google Chrome can't find background image

I have a button that I want to change the background of to show that it is disabled when a user clicks on it. It works fine in IE/FF but in chrome it seems that it can't find the background image and makes the background nothing. I am just doing a simple css set in jQuery 1.2.6 $(".CheckoutBt").css("background-image", "url(/Portals/_...

Stretch and Scale a CSS image Background - With CSS only

Good day. I always wanted to do this. I want that my background image stretch and scale depending the Browser view port size. I've seen some questions on SO that do the job, this One for example. Works well, but i want place the img in the background way, not with a image tag. In that one is placed a img tag, then with CSS we tribute...

ie6 css background image problem

Hi, I have a CSS style which displays a png image in background. It works well in all browser, except in ie6. In ie6 the bacground image is stretched to fit the block. How do I solve this ? Here's the CSS which I'm using to do this. .error { color: #D8000C; background-color: #FFBABA; background-image: url('error.png'); } ...

Set size on backgroundimage with css?

Is it possible to set the size of the backgroundimage with css? I want to do something like: background: url('bg.gif') top repeat-y; background-size: 490 px; But it seems it's totally wrong to do like that... ...

Moving a background image X pixels every X milliseconds

I have an image sprite of sorts with multiple frames for 1 button. I'm looking to "play" through the frames on rollover of the link/button using jQuery. Currently the image is set as the background of the button using CSS, so I'm looking to change the background position every ~30ms by ~40px along the Y axis (but I can change the directi...

CSS sliding door background image problem.

I noticed I am not the first to ask about CSS sliding doors. However this seems (at least to me) to be a rather odd problem which I have not seen an answer for. Trying to create a simple rounded corner link button: html: <a href="#" class="link_button"><span>Add A New Somthing</span></a> css: .link_button { background...

CSS background: set position then do a shift?

The background-position property can be set in a variety of ways such as "top right" or "16px 16px" or "50% 75%" etc. Question: is there a way to position a background image then offset that position? For example: set the background-position to "top right" then shift it left 16px and down 16px using "-16px 16px"? ...

div background image appear nicely in Firefox, disappear in IE6 & 7

Hi all, I'm really really new to HTML/CSS, but somehow decided to plunge head on to using 960 Grid System, which I found helpful. I know some says it's unsemantic, but I've been involved and at the end, tangled in the problem stated above. I've tried a few codes like overflow: hidden, overflow: auto, display: block, etc that I found on o...

IE6 background misaligned

I have IE6. [EDIT: you can see the template live here: http://themeforest.net/item/aqua-terra-lava-html-blog-portfolio-/full_screen_preview/53209 ] I have a template, with 3 <a></a> that change the position of their background to create a button effect. This is how it looks in any browser This is it with IE6: This the CSS code: ...

Two separate background images.

I want to have my page to have two background images: one at the top, and one at the bottom. I don't want them static, though. How would I do this? ...

Can you find an image in CSS?

I'm just starting to learn CSS. A way I like to learn is to copy source code from a site I admire, and then sort of "rebuild" it myself to learn how it was done. I am not using that site, or stealing it -- I am just practicing from it. For example, I will take various s from the style sheet and then play with it in my own page to see how...

How to access property in "style" attribute with jQuery?

Is there a possibility to access a i.e "background-image:url()" property inside an inline "style" attribute? In other words going layers "deeper" than attr('style') does. I want to manipulate the url inside style="background-image:url(something);" ...

CSS - using an image along with an accent line for a paragraph heading.

A common, and good looking, typographical effect is a small image, maybe a stylized arrow, some text, and an accent line. Something like this: -> Now this paragraph --------------------------------- Where the "->" is some kind of small graphic, and the "-------" is an accent line, maybe colored. I would like to do this in css, so in a...

List of All Background Images in DOM

What's the best way to find all of the background images on a given page using javascript? The ideal end result would be an array of all of the url's. ...

How do you position a background image inside a <div>?

My code currently looks like this: <div style="position: fixed; width: 35.25%; height: 6.75%; left: 0%; top: 4.625%; right: 64.75%; bottom: 88.625%; color: #D1E231; text-align: center; background-color: #666666; background-image: url('FleurTR.png'); background-position: right top;"> <div> The <div> shows up just fine, with...

Top Container Background Problem

Here's a screenshot: The red bar on the left is the background I set for the #personal div and I would like it to align to the top of the container, vertically. The problem is that I have a background for the #container-top div on top of the #container div with absolute positioning. Is there any way to move the #personal div up so th...

Css background layers and 100% height div's

Imagine the following code. <body id="first_bg_layer"> <div id="second_bg_layer"> <div id="third_bg_layer"> </div> </div> </div> Each layer has a different background that is static/repeated to achieve the desired effect. I need all layers to fill up the screen, otherwise the background will be broken. The background is sp...

What is wrong with this CSS?

I have the following CSS code: .yellow { background-image: url('/images/yellowlight.png'); background-repeat: no-repeat; height:100%; width:100%; } and the following HTML code: <div class="yellow">&nbsp;</div> However, the div on the page does not have the image. You can see this by clicking on the blue "Logs Status...

Sprite background image lags on mouse hover

I have basic DOM menu that has sprite background images for the first level of "LI"s. It works just fine, but I guess there is some problem and instead of switching the image right away on hover it goes blank and after about a second the hover image "appears" (shifts). That happens only on first hovering. After that it's smooth like it'...

Fixed background on iPhone Safari

iPhone Safari seems to have some sort of problem whereby a page with css like this: body { background: #000 url(fixedimage.png) fixed repeat-x; } ...doesn't actually lead to a fixed image. It scrolls as the user scrolls. I've seen plenty of people kvetching about this on the internets, but no real solution. Does anyone have any id...