• datalist显示商品列表


    DataList横向显示数据

    <asp:datalist id="MyList" RepeatDirection=Horizontal RepeatColumns=2 showfooter=true borderwidth=0 runat=server>
                     <HeaderTemplate>
                     <table height=100% width=288 cellpadding=0 cellspacing=0 border=0 >
                     <tr>
                     </HeaderTemplate>
                     <ItemTemplate>
                             <td>
                              <table>
                              <tr>
                              <td width=130>
                               <a href="Hotel/hotelDetail.aspx?H_ID=<%# DataBinder.Eval(Container.DataItem, "H_ID")%>" target=_blank><img height="90" width="130" border=0 src="HotelManage/pic/<%# DataBinder.Eval(Container.DataItem, "H_Pic1")%>" /></a>
                              </td>
                              </tr>
                              <tr>
                              <td>
                               <%# DataBinder.Eval(Container.DataItem, "H_Name")%>
                              </td>
                              </tr>
                              </table>
                            </td>   
                  </ItemTemplate>
                  <FooterTemplate>
                    </tr>
                      </table>
                  </FooterTemplate>
               </asp:datalist>

    RepeatDirection=Horizontal 为设置为横向显示

    RepeatColumns=2 每行显示2条记录

  • 相关阅读:
    SDRAM(3):刷新和仲裁
    SDRAM(2):初始化
    SDRAM(1):基本介绍
    计数器(3):避免多计少计
    协议——SPI
    matlab数字图像处理 入门基础
    gVim编辑器——基本设置、常用命令、代码片段
    Pomelo的Router
    Pomelo聊天室框架
    Pomelo术语解释
  • 原文地址:https://www.cnblogs.com/zzxap/p/2175905.html
Copyright © 2020-2023  润新知