我的blockquote没有运行。我也链接了bootstrap css和js文件,但似乎不起作用

时间:2019-07-08 09:27:34

标签: javascript css bootstrap-4

我已经从引导程序链接了下载的css和js文件,但是这些功能似乎无法正常工作。 <blockquote>标签只是返回简单文本。 <cite> </cite>也不给我“-”。似乎是什么问题?

<head>
  <title>Bootstrap Cheat Sheet</title>
  <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" type="text/css" href="css/bootstrap.min.css">
  <link rel="stylesheet" type="text/css" href="css/custom.css">
</head>

<body>
  <!-- Block Quotes -->

  <blockquote class="blockquote">
    <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. </p>
    <footer>Quote By <cite title="John Doe">John Doe</cite></footer>
  </blockquote>

1 个答案:

答案 0 :(得分:1)

证明您已正确加载bootstrap.css文件(可以在开发人员工具中检查控制台)...并且您的custom.css没有覆盖blockquote类... < / p>

下面的代码段应该适合您:

<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">
<div class="container">

  <blockquote class="blockquote">
    <p>For 50 years, WWF has been protecting the future of nature. The world's leading conservation organization, WWF works in 100 countries and is supported by 1.2 million members in the United States and close to 5 million globally.</p>
    <footer class="blockquote-footer">From WWF's website</footer>
  </blockquote>

  <blockquote class="blockquote">
    <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. </p>
    <footer>Quote By <cite title="John Doe">John Doe</cite></footer>
  </blockquote>
</div>