2017-01-26 3 views
0

brauche ich Bootstrap glyphicon CheckboxBootstrap glyphicon Checkbox CSS

<label class="checkbox-inline"><input type="checkbox" value=""/> 
    To Download<div class="glyphicon glyphicon-download"></div> 
</label> 

Aber ich tun möchte glyphicon an Stelle von Kontrollkästchen setzen. Vielen Dank im Voraus für die Antworten

+0

http://jsfiddle.net/t7gAR/579/ Snippet –

Antwort

1

dieses Probieren Sie es funktioniert ..

Der Arbeitscode

.glyphicon:before { 
 
visibility: visible; 
 
} 
 
.glyphicon.glyphicon-download:checked:before { 
 
    content: "\e013"; 
 
} 
 
input[type=checkbox].glyphicon{ 
 
    visibility: hidden; 
 
    
 
}
<!doctype html> 
 
<html lang="en"> 
 
<head> 
 
<meta charset="utf-8"> 
 
<meta http-equiv="X-UA-Compatible" content="IE=edge"> 
 
<meta name="viewport" content="width=device-width, initial-scale=1"> 
 

 
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css"> 
 
      <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script> 
 
      <script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script> 
 

 

 

 
</head> 
 
<body> 
 
<label class="checkbox-inline"><input type="checkbox" class="glyphicon glyphicon-download" value=""/> 
 
    To Download 
 
</label> 
 
</body> 
 
</html>

Verwandte Themen