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 8235973
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T18:59:49+00:00 2026-06-07T18:59:49+00:00

I know how to do border opacity , how to do background image opacity

  • 0

I know how to do border opacity, how to do background image opacity, but I would like to have an element without border opacity, having backround-image opacity on. I don’t want to modify image in image editor, so I am looking for opacity set by CSS. Possible?

In my CSS below I want to modify “disabled” status with sharp no-opacity border. Please advice…

Example of use: this fiddle


button style:

  div.button, div.button:hover
  {
    background: none;
    border: 2px solid #6C7B8B;
    border-radius: 8px;
    clear: none;
    color: transparent;
    cursor: pointer;
    display: inline-block;
    filter: alpha(opacity=100);
    -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";
    float: none;
    height: 24px;
    margin-bottom: 0px;
    margin-left: 3px;
    margin-right: 0px;
    margin-top: 7px;
    opacity: 1;
    -moz-opacity: 1;
    outline: none;
    overflow: hidden;
    padding: none;
    vertical-align: top;
    width: 24px;
  }

click effect:

  div.button:active
  {
    left: 1px;
    position: relative;
    top: 1px;
  }

extra style for status DISABLED:

  div.disabled, div.disabled:hover
  {
    cursor: default;
    filter: alpha(opacity=50);
    -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";
    opacity: 0.50;
    -moz-opacity: 0.50;
  }

  div.disabled:active
  {
    left: 0px;
    position: relative;
    top: 0px;
  }

extra style for status ON:

  div.on, div.on:hover
  {
    border: 2px solid #007FFF;
  }
  • 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-06-07T18:59:50+00:00Added an answer on June 7, 2026 at 6:59 pm

    You’re just in the same situation as CSS: set background image with opacity? – you want to have a transparent background, but non-transparent content (to whom the border counts).

    So as in CSS3 there is nothing such a background-image-opacity, you can only build a transparent image or position two elements over each other, the lower containing the image (as suggested by the answers there).

    But in your case it would be enough to shade the image. This could for example been done by using transparent image from the beginning, but change the underlaying background-color. Or you’d use

    <div class="button" title="Zoom!"><img src="icon.gif" alt="glasses" /></div>
    

    with

    div.button.disabled img { opacity: .5; }
    

    which makes more sense semantically, too. You should get away from those inline styles.

    (updated fiddle)

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

Sidebar

Related Questions

I would to know how to have a border to separate my buttons in
You know, like Battlestar paper! I have given this a few goes but now
I'd like to know how to change the width of the border of this
If you know that you have to show tens of texts with a border
I want to change only bottom border style. Is it possible? I know this
I want to know how Qt does a border when using QPainter's drawRect. The
I'm trying to get the css value of the background-image of some div, but
I know it's possible to skew but I don't see a way to skew
Does anyone know how to add a border to a Dockpanel. i have this:
I don't know why this doesn't show a extra border can you see what

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.