Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3796540
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T13:15:07+00:00 2026-05-19T13:15:07+00:00

I want to get rgba backgrounds working with all browsers. I did some searching

  • 0

I want to get rgba backgrounds working with all browsers. I did some searching and found out that generally there are three types of browsers out there:

1) Browsers that support rgba.

2) Internet Explorer that supports rgba via bizarre ‘-ms-filter’ thing.

3) Browsers that do not support rgba, but I could use base64 png images with ‘data URI scheme’. (Even when browser does not support URI scheme, according to this it still could be done.)

I have no problems with rgba supporting browsers, and I can get it working with IE, but problem is that I have no idea how to generate client side base64 png images for URI scheme. I really do not want to pregenerate png files, because my rgba values are not constant. I could go with dynamic png generation with php gd library, but I’d really like to do all this on client side. So I’d like to know, is there any good way out there for generating semi-transparent png images with java-script. After this I could just base64 encode them and use them with URI scheme?

Thank you.

Edit:

I want to have semi-transparent div background, while having content fully visible.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T13:15:07+00:00Added an answer on May 19, 2026 at 1:15 pm

    See this blog post for a cross browser method:

    .alpha60 {
        /* Fallback for web browsers that doesn't support RGBa */
        background: rgb(0, 0, 0);
        /* RGBa with 0.6 opacity */
        background: rgba(0, 0, 0, 0.6);
        /* For IE 5.5 - 7*/
        filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000);
        /* For IE 8*/
        -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000)";
    }
    

    Web browser support

    RGBa support is available in: Firefox
    3+ Safari 2+ Opera 10

    Filters in Internet Explorer are
    available since Internet Explorer 5.5.

    This means that this will work for
    virtually everyone!

    See here for an easy way to generate the colors for the IE filters.

    Doing this should eliminate the need to use “base64 png images with ‘data URI scheme'”.


    If you really, really want to generate client side .png images (I can’t see the need for it here):

    Generate client-side PNG files using JavaScript. Cool idea, really:

    It was once again one of those nights
    where I hacked like on drugs with no
    end in sight. Sure, 5 years ago you
    had loved me with such a project, but
    in times of HTML5 with the canvas
    element it is hard to impress you. So
    take it as proof of creating client
    side images without canvas, SVG, or
    server side rendering and AJAX
    processing.

    But how is this possible? Well, I’ve
    implemented a client-side JavaScript
    library like libpng which creates a
    PNG data stream. The resulting binary
    data can be appended to the data
    URI-scheme using Base64 encoding.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want get all of the Geom objects that are related to a certain
i want query a file xml with linq, i want get all descendat of
I have a color and I want get a tint of that color by
A want get all information which are in located in <forecast_conditions></forecast_conditions> tag for first
I have some RGBA data in Python 3 and I want to display the
I have image data and i want to get a sub image of that
I want to try and get a cross browser gradient effect working with rgb
I want to create loader mask for all page. I need to get the
I want get the time used for a case so I can create an
I want get as much as possible from Redis + Hiredis + libevent. I'm

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.