html - Background gradient fill for flexible div's, either using css or images? -
I am using a certain height image so that fill a device with gradient color which: background: transparent url (Green_bg.gif) Repetitive-X scroll 0 0;
While this is just the height of the fill image, what is the best way to fill a div's backfind, which changes the height, according to the amount of text in it, either of the images Using or Using CSS?
I think what you want is that a background is a background image (which is a gradient ) And then the rest of the way with a solid color?
If so, in Photoshop (or image editor of your choice), get the hex of the last pixel in your shield for logic, assuming it is #FF0000 then do this:
.mydiv {background: # FF0000 url (green_bg.gif) repeat-x0; }
This will fill your background with #FF 20000 (red) and overlay its background image above it, starting from the top of your div, the horizontal (X-axis) ) Repeat. The way to display red background is to increase the amount of content in your div.
In addition to this, if you want to make sure that you are always showing a certain part of your shield, then you padding-top
in your CSS
.mydiv {background: # FF0000 url (green_bg.gif) repeat-x 0 0; Padding-top: 20px; }
If it is not, please clarify in your question.
Comments
Post a Comment