CSS Transparent Buttons with Borders

I am trying to make a button in css like this

but i have no idea how to do this since i'm new to css. This is what I tried:

.gbtnHollow  {
     background:  transparent;
     height:  38px;
     line-height:  40px;
     border:  2px solid white;
     display:  inline-block;
     float:  none;
     text-align:  center;
     width:  120px;
     padding:  0px!important;
     font-size:  14px;
     color:  #fff;
 }

.gbtnHollow:hover  {
     color:  #fff;
     background:  rgba(255, 255, 255, 0.2);
 }
+4
source share
4 answers

It is very simple, set background: none;to a button. Jsfiddle

+3
source
button {
    background-color: Transparent;
    background-repeat:no-repeat;
    cursor:pointer;
    overflow: hidden;
    outline:none;
}

Add this and configure it for yourself. Example here is fiddle

+1
source

Simple add this css to the button:

button {
    background: none;/*this for transparent button*/
    border: 1px solid black;/* this is for button border*/
    position: relative;
    left: 150px;
    top: 80px;
}
+1
source

enter image description hereenter image description here

#button {
     width: 150px;
     height: 50px;
     border:none;
     border:solid 2px black;
     border-radius: 5px;
     background: rgba(255, 255, 255,0);
     font-size: 25px;
}

#button:hover {
     background:black;
     color:white; 
}
+1
source

All Articles