-3

my object is transparent but has a nice borders. Can I show only these borders in CSS or HTML?

I_love_pugs
  • 103
  • 6
  • Not sure if I understand correctly but if you want to display a border in CSS simply target whatever element your object is under and put `border:1px solid #000;`. So for example if it was a `

    ` tag you would do `p { border:1px solid; }`
    – Jorden May 22 '17 at 16:13
  • No, I have a button with nice borders and I want to set opacity of this button to 0. The problem is that I don't want my borders to dissapear. – I_love_pugs May 22 '17 at 16:17
  • 1
    if you want to keep the borders of the button element but keep the fill of the button transparent, do `button { background:transparent; }` – Jorden May 22 '17 at 16:19

1 Answers1

1

I don't quite understand what you mean, you were pretty vague and didn't post any code. But if you are saying you want to keep the border but get rid of opacity I put some CSS code below that should help.

        .btn {
border: 4 px;
border-color: black;
color: black; 
padding: 14px 28px; 
cursor: pointer; 
font-weight: bold;
opacity: 1;
}

.bttn {background-color: white;} 
.bttn:hover {background-color: #f2f2f2;}

If you are trying to keep your borders and use opacity set the opacity to 1. Or if you are trying to use an opacity less than one add something like so.

.bttn a {
 border: 4px;
 border-style: solid;
 border-color: black;
}

Hope this helps.