菜单切换
FACESOHO知行者
心灵
记录
远方
赞赏工具
源代码:
点击运行
保存
<!DOCTYPE html> <html> <head> <title>Bootstrap 实例</title> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://cdn.staticfile.org/twitter-bootstrap/4.1.0/css/bootstrap.min.css"> <script src="https://cdn.staticfile.org/jquery/3.2.1/jquery.min.js"></script> <script src="https://cdn.staticfile.org/popper.js/1.12.5/umd/popper.min.js"></script> <script src="https://cdn.staticfile.org/twitter-bootstrap/4.1.0/js/bootstrap.min.js"></script> </head> <body> <div class="container"> <h2>排版</h2> <p class="text-left">左对齐</p> <p class="text-right">右对齐</p> <p class="text-center">居中对齐文本</p> <p class="text-justify">设定文本对齐,段落中超出屏幕部分文字自动换行</p> <p class="text-nowrap">段落中超出屏幕部分不换行</p> <p><strong>提示:</strong> 重置浏览器窗口大小查看换行效果。</p> </div> </body> </html>
运行结果