I am attempting to create a dynamic header using a diagonal pattern above a gradient image. The size of the header varies per the width of the page, so due to my lack of CSS knowledge I have run into transparency issues. At the moment I have a #header which sets up the size and position and repeats the header image across the x axis. The #overlay controls the repetition of the overlay gif and sets the opacity to 15. The overlay div sits inside the header div, and everything displays nicely until I add text. Since everything in the overlay div displays with 15% transparency, the text becomes unreadable. How do I go about making the text with in the overlay not follow the transparency of the div?
Here's some code:
CODE
#overlay {
height: 100%;
-moz-opacity:0.15;
filter:alpha(opacity=15);
background-image: url(overlay.gif);
background-repeat: repeat;
}
#header {
color: #ffffff;
padding: 0px;
height: 100px;
background-image: url(header.jpg);
background-repeat: repeat-x;
}
<div id="header">
<div id="overlay">
<img border="0" src="logo.jpg">
<p> header text </p>
</div>
</div>
height: 100%;
-moz-opacity:0.15;
filter:alpha(opacity=15);
background-image: url(overlay.gif);
background-repeat: repeat;
}
#header {
color: #ffffff;
padding: 0px;
height: 100px;
background-image: url(header.jpg);
background-repeat: repeat-x;
}
<div id="header">
<div id="overlay">
<img border="0" src="logo.jpg">
<p> header text </p>
</div>
</div>