USING CSS, HOW TO MAKE THE BACKGROUND OF AN ELEMENT TRANSPARENT/SEMI-TRANSPARENT BUT HAVE THE CONTENT (TEXT & IMAGES) OF THE ELEMENT OPAQUE?

Using CSS ,how to make the background of an element transparent/semi-transparent but have the content (text & images) of the element opaque?

Give opacity as 0.5 in your background color rgba like background-color:rgba(255,0,0,0.5); based on your color in your style property of the element tag.

Eg.
<p style=”background-color: rgba(255,0,0,0.5);”></p>

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>