如何在 Bootstrap 中使用 Glyphicons 图标
若要在 Bootstrap 中使用 Glyphicons 图标,只需在代码中几乎任何地方使用以下代码即可。为了适当填充,请在图标和文本之间留一个空格,如下所示 −
示例
<!DOCTYPE html> <html> <head> <title>Bootstrap Example</title> <link href = "/bootstrap/css/bootstrap.min.css" rel = "stylesheet"> <script src = "/scripts/jquery.min.js"></script> <script src = "/bootstrap/js/bootstrap.min.js"></script> </head> <body> <span class = "glyphicon glyphicon-user"></span> </body> </html>
您可以尝试运行以下代码以实现 Glyphicons 图标
示例
<!DOCTYPE html> <html> <head> <title>Bootstrap Example</title> <link href = "/bootstrap/css/bootstrap.min.css" rel = "stylesheet"> <script src = "/scripts/jquery.min.js"></script> <script src = "/bootstrap/js/bootstrap.min.js"></script> </head> <body> <p>The following are the icons:</p> <p> <button type = "button" class = "btn btn-default"> <span class = "glyphicon glyphicon-print"></span> </button> <button type = "button" class = "btn btn-default"> <span class = "glyphicon glyphicon-search"></span> </button> <button type = "button" class = "btn btn-default"> <span class = "glyphicon glyphicon-download"></span> </button> </p> </body> </html>
广告
数据结构
网络
关系型数据库管理系统
操作系统
Java
iOS
HTML
CSS
Android
Python
C 编程
C++
C#
MongoDB
MySQL
Javascript
PHP