Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/twitter-bootstrap/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Twitter bootstrap 谷歌用Bootstrap美化:行号不显示_Twitter Bootstrap_Prettify_Google Code Prettify - Fatal编程技术网

Twitter bootstrap 谷歌用Bootstrap美化:行号不显示

Twitter bootstrap 谷歌用Bootstrap美化:行号不显示,twitter-bootstrap,prettify,google-code-prettify,Twitter Bootstrap,Prettify,Google Code Prettify,我正在使用谷歌美容与推特引导。它正在工作,但由于某种原因,行号没有出现 以下是标记: 公众的 推翻 无效的 处置 () { 基础 . 处置 (); } 我这样称呼它: $(文档).ready(函数(){ 预打印(); }); 我没有任何自定义CSS。。仅使用引导CSS..我建议您使用以下两个文件: 并在页脚中添加以下内容: <script> !function ($) { $(function(){ window.prettyPri

我正在使用谷歌美容与推特引导。它正在工作,但由于某种原因,行号没有出现

以下是标记:


  • 公众的 推翻 无效的 处置 ()
  • {
  • 基础 . 处置 ();
  • }
  • 我这样称呼它:

    
    $(文档).ready(函数(){
    预打印();
    });
    

    我没有任何自定义CSS。。仅使用引导CSS..

    我建议您使用以下两个文件:

    并在页脚中添加以下内容:

    <script>
      !function ($) {
        $(function(){
          window.prettyPrint && prettyPrint()   
        })
      }(window.jQuery)
    </script>
    
    
    !函数($){
    $(函数(){
    window.prettyPrint&&prettyPrint()
    })
    }(window.jQuery)
    

    在from中找到,请确保没有列表样式:无;CSS文件中的任意位置。

    默认样式表的操作部分是

    li.L0,
    li.L1,
    li.L2,
    li.L3,
    li.L5,
    li.L6,
    li.L7,
    li.L8 { list-style-type: none }
    
    这将关闭索引为i的所有项目的列表项目符号,其中(i%10)∉ (4,9)

    添加高优先级样式将覆盖prettify.css中的默认样式,因此您无需提出自己的主题

    <style>
    li.L0,
    li.L1,
    li.L2,
    li.L3,
    li.L5,
    li.L6,
    li.L7,
    li.L8 { list-style-type: decimal !important }
    </style>
    
    
    li.L0,
    li.L1,
    li.L2,
    li.L3,
    li.L5,
    li.L6,
    li.L7,
    li.L8{列表样式类型:decimal!important}
    

    应该这样做。

    您能解释一下脚本片段在做什么吗?