Last active
August 10, 2017 16:31
-
-
Save petvas/b060d0ff45ffcf2c4cdac4af94b503c7 to your computer and use it in GitHub Desktop.
Simple star rate with Glyphicons
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> | |
<style type="text/css"> | |
.stars { | |
position: relative; | |
width: 70px; | |
height: 20px; | |
} | |
.stars:before, | |
.stars:after { | |
display: block; | |
position: absolute; | |
top: 0; | |
left: 0; | |
overflow: hidden; | |
font-family:"Glyphicons Halflings"; | |
} | |
.stars:before { | |
color: #ddd; | |
content:"\e007\e007\e007\e007\e007"; | |
} | |
.stars:after { | |
width: 72%; | |
color: #f00; | |
content:"\e006\e006\e006\e006\e006"; | |
} | |
</style> | |
</head> | |
<body> | |
<div class="stars"></div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment