如何在datalist中的两行之间插入空格 [英] How to insert space between two rows in a datalist

查看:117
本文介绍了如何在datalist中的两行之间插入空格的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试使用以下代码在两行datalist之间留出空间。没有错误,但没有插入空间。在项目模板之后,我包含了类似的代码..



。Dt_RowSeparator {margin:0px 0px 0px 0px; } 

< / style >




< separatorstyle / >
< separatortemplate >
< h4 class = Dt_RowSeparator > < / h4 >
< / separatortemplate >

解决方案

下面的样式应该工作



 Dt_RowSeparator  

{
height 2px;
margin 5px auto 5px auto;
vertical-align middle ;
background-color #E9E7E3;
}


 < ;   style     type   =  text / css >  
clear {
padding-left 10px;
padding-bottom 10px!重要;
}
< / style >





在ItemTamplate下添加这个

< SeparatorTemplate>< div class =clear>< / div>< / SeparatorTemplate> ; 


I tried with the following code to give space between 2 rows of the datalist. No error but space not inserted. After Item template I included the code like..

.Dt_RowSeparator { margin: 0px 0px 0px 0px; }

    </style>



   
<separatorstyle />
<separatortemplate>
    <h4 class="Dt_RowSeparator"></h4>
</separatortemplate>

解决方案

Below style should work

.Dt_RowSeparator

{
height: 2px;
margin: 5px auto 5px auto;
vertical-align: middle;
background-color:#E9E7E3;
}


<style type="text/css">
        .clear {
            padding-left:10px;
            padding-bottom:10px!Important;
        }
    </style>



add this under ItemTamplate

<SeparatorTemplate><div class="clear"></div></SeparatorTemplate>


这篇关于如何在datalist中的两行之间插入空格的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆