Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/262.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
C# ASP.NET列表视图填充_C#_Asp.net_Css - Fatal编程技术网

C# ASP.NET列表视图填充

C# ASP.NET列表视图填充,c#,asp.net,css,C#,Asp.net,Css,我使用两个列表视图来显示两个标记云(一个红色的和一个绿色的)。当标签变得相当大时,它会与较小的标签重叠。有没有办法把标签隔开,比如垂直填充或其他什么 <div style="padding-left: 25px; padding-right: 25px; text-align: center;"> <asp:listview runat="server" ID="ListView1" ItemPlaceholderID="itemPlaceHolder"> <Lay

我使用两个列表视图来显示两个标记云(一个红色的和一个绿色的)。当标签变得相当大时,它会与较小的标签重叠。有没有办法把标签隔开,比如垂直填充或其他什么

<div style="padding-left: 25px; padding-right: 25px; text-align: center;">
<asp:listview runat="server" ID="ListView1" ItemPlaceholderID="itemPlaceHolder">
<LayoutTemplate>
    <asp:PlaceHolder runat="server" ID="itemPlaceHolder"></asp:PlaceHolder>
</LayoutTemplate>
<ItemTemplate>
    <a href="negativestorydetail.aspx?tag=<%# Eval("Tag") %>" style="color: #ff0000; text-align: center; margin: 15px; text-decoration:none; font-size: <%# GetTagSize(Convert.ToDouble(Eval("weight"))) %>"><%# Eval("Tag") %></a>
</ItemTemplate>
<EmptyDataTemplate>
    <asp:Label ID="negative_tags" runat="server" Text=""></asp:Label>
</EmptyDataTemplate>
</asp:listview>
</div>

<br />

<div style="padding-left: 25px; padding-right: 25px; text-align: center;">
<asp:listview runat="server" ID="ListView2" ItemPlaceholderID="itemPlaceHolder">
<LayoutTemplate>
    <asp:PlaceHolder runat="server" ID="itemPlaceHolder"></asp:PlaceHolder>
</LayoutTemplate>
<ItemTemplate>
    <a href="positivestorydetail.aspx?tag=<%# Eval("Tag") %>" style="color: #33cc00; text-align: center; margin: 15px; text-decoration:none; font-size: <%# GetTagSize(Convert.ToInt32(Eval("weight"))) %>"><%# Eval("Tag") %></a>
</ItemTemplate>
<EmptyDataTemplate>
    <asp:Label ID="positive_tags" runat="server" Text=""></asp:Label>
</EmptyDataTemplate>
</asp:listview>
</div>

标签上,您可以添加:

行高:30px

或者,您也可以添加

填充顶部:5px;填充底部:5px