Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/76.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
html中编号列表的html代码,如(a)_Html_Internet Explorer 7 - Fatal编程技术网

html中编号列表的html代码,如(a)

html中编号列表的html代码,如(a),html,internet-explorer-7,Html,Internet Explorer 7,我需要创建编号为(a)、(b)等的列表元素 我试过如下方法 <ol type="a"> <li>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley

我需要创建编号为(a)、(b)等的列表元素

我试过如下方法

<ol type="a">
<li>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
</li>
<li> Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
</li>
</ol>

  • Lorem Ipsum只是印刷和排版行业的虚拟文本。自16世纪以来,Lorem Ipsum一直是行业标准的虚拟文本,当时一位不知名的印刷商拿起一个打印工具,将其拼凑成一本打印样本书。它不仅存活了五个世纪,而且还跨越到电子排版,基本上保持不变。它在20世纪60年代随着包含Lorem Ipsum段落的Letraset表单的发布而流行,最近随着Aldus PageMaker等桌面出版软件的发布,包括Lorem Ipsum版本。
  • Lorem Ipsum只是印刷和排版行业的虚拟文本。自16世纪以来,Lorem Ipsum一直是行业标准的虚拟文本,当时一位不知名的印刷商拿起一个打印工具,将其拼凑成一本打印样本书。它不仅存活了五个世纪,而且还跨越到电子排版,基本上保持不变。它在20世纪60年代随着包含Lorem Ipsum段落的Letraset表单的发布而流行,最近随着Aldus PageMaker等桌面出版软件的发布,包括Lorem Ipsum版本。
  • 然而,与其拥有。。。b。。。我想要(一)。。。和(b)

    是否有特殊类型的带括号的编号信件列表

    也需要它在IE7上工作

    IE 7解决方案(?)

    }

    关于自定义ol编号,也有一个类似的问题:


    不,没有HTML方法生成编号,例如“(a)”。
    ol
    type
    属性的值集非常有限。对于相应的CSS结构,
    列表样式类型
    属性还有更多的值,但即使对于它,也需要设置“数字”的样式,而不是它们周围的标点符号

    现在常用的方法是使用CSS计数器和生成的内容,但这在IE7上不起作用

    假设标记和内容不能更改,那么只剩下JavaScript方式。然后,您可以将
    ol
    元素替换为
    div
    元素,将
    li
    元素更改为
    div
    元素,并在其前面添加类似“(a)”的内容和适当的样式(边距)

    var i =0;
                                                            // A is #65 in Unicode
    $("ol").children()
           .prepend('<span class="li-counter">(' + String.fromCharCode(64+(i++)) + ')' );
    
    ol {
        counter-reset: my-counter;
    }
    ol li:before {
        content: "(" counter(my-counter, lower-alpha) ")"; 
        counter-increment: my-counter;
        margin-right: 5px;
        font-weight: bold;