productsclickssaletop.ascx

来自「电子商城源代码,包含项目工程文件! 数据库建表语句 具体功能包括电子购物车,」· ASCX 代码 · 共 66 行

ASCX
66
字号
<%@ Control Language="c#" AutoEventWireup="false" Codebehind="ProductsClicksSaleTop.ascx.cs" Inherits="EMall.UserControls.ProductsClicksSaleTop" TargetSchema="http://schemas.microsoft.com/intellisense/ie5"%>
<asp:datalist id="DataList1" GridLines="Horizontal" CellPadding="4" BackColor="White" BorderColor="#E3E3E3"
	DataKeyField="ProductID" BorderWidth="1px" Width="100%" runat="server" HeaderStyle-BackColor="#E3E3E3"
	HeaderStyle-BorderColor="Peachpuff" Height="34">
	<SelectedItemStyle Font-Bold="True" ForeColor="White" BackColor="#339966"></SelectedItemStyle>
	<HeaderTemplate>
		<TABLE cellSpacing="0" cellPadding="0" width="100%" align="center" border="0">
			<TR>
				<TD width="10"></TD>
				<TD><b><% = sMsg%>热门商品</b></TD>
				<TD width="20">点</TD>
				<TD width="20">销</TD>
			</TR>
		</TABLE>
	</HeaderTemplate>
	<AlternatingItemStyle BackColor="WhiteSmoke"></AlternatingItemStyle>
	<FooterTemplate>
		<a href="ProductsTop.aspx?OB=Clicks" alt="点击查看更多相关商品...">More...</a>
	</FooterTemplate>
	<ItemStyle ForeColor="#333333" BorderStyle="None" BackColor="White"></ItemStyle>
	<ItemTemplate>
		<table align="center" border="0" cellpadding="0" cellspacing="1" width="100%">
			<tr>
				<td width="10"><a href='<%# "AddToCart.aspx?ProductID=" + DataBinder.Eval(Container.DataItem, "ProductID") %>' target=A><img src="Images/ShoppingCart.gif" border="0" title="点击订单此商品"></a></td>
				<td><a href='<%# "Product.aspx?ProductID=" + DataBinder.Eval(Container.DataItem,"ProductID")%>' title='<%# "商品: " + DataBinder.Eval(Container.DataItem,"ModelNumber").ToString() + DataBinder.Eval(Container.DataItem,"ModelName").ToString() + "\n\n品牌: " + DataBinder.Eval(Container.DataItem,"Vendor").ToString() + "\n说明: " + DataBinder.Eval(Container.DataItem,"Description").ToString() %>' target=P><%# pub.GetSubString(DataBinder.Eval(Container.DataItem,"ModelNumber").ToString() + DataBinder.Eval(Container.DataItem,"ModelName").ToString(), 10)%></a></td>
				<td width="20"><%# DataBinder.Eval(Container.DataItem,"Clicks")%></td>
				<td width="20"><%# DataBinder.Eval(Container.DataItem,"Sales")%></td>
			</tr>
		</table>
	</ItemTemplate>
	<FooterStyle HorizontalAlign="Right" ForeColor="#333333" BackColor="#E3E3E3"></FooterStyle>
	<HeaderStyle Font-Bold="True" Height="26px" ForeColor="White"></HeaderStyle>
</asp:datalist>
<br>
<asp:datalist id="Datalist2" GridLines="Both" CellPadding="4" BackColor="White" BorderColor="#E3E3E3"
	DataKeyField="ProductID" BorderWidth="1px" Width="100%" runat="server" HeaderStyle-BackColor="#E3E3E3">
	<SelectedItemStyle Font-Bold="True" ForeColor="#CCFF99" BackColor="#009999"></SelectedItemStyle>
	<HeaderTemplate>
		<TABLE cellSpacing="0" cellPadding="0" width="100%" align="center" border="0">
			<TR>
				<TD width="10"></TD>
				<TD><b><% = sMsg%>热销商品</b></TD>
				<TD width="20">点</TD>
				<TD width="20">销</TD>
			</TR>
		</TABLE>
	</HeaderTemplate>
	<AlternatingItemStyle BackColor="WhiteSmoke"></AlternatingItemStyle>
	<FooterTemplate>
		<a href="ProductsTop.aspx?OB=Sales" alt="点击查看更多相关商品...">More...</a>
	</FooterTemplate>
	<ItemStyle ForeColor="#003399" BorderStyle="None" BackColor="White"></ItemStyle>
	<ItemTemplate>
		<table align="center" border="0" cellpadding="0" cellspacing="1" width="100%">
			<tr>
				<td width="10"><a href='<%# "AddToCart.aspx?ProductID=" + DataBinder.Eval(Container.DataItem, "ProductID") %>' target=A><img src="Images/ShoppingCart.gif" border="0" title="点击订单此商品"></a></td>
				<td><a href='<%# "Product.aspx?ProductID=" + DataBinder.Eval(Container.DataItem,"ProductID")%>' title='<%# "商品: " + DataBinder.Eval(Container.DataItem,"ModelNumber").ToString() + DataBinder.Eval(Container.DataItem,"ModelName").ToString() + "\n\n品牌: " + DataBinder.Eval(Container.DataItem,"Vendor").ToString() + "\n说明: " + DataBinder.Eval(Container.DataItem,"Description").ToString() %>' target=P><%# pub.GetSubString(DataBinder.Eval(Container.DataItem,"ModelNumber").ToString() + DataBinder.Eval(Container.DataItem,"ModelName").ToString(), 10)%></a></td>
				<td width="20"><%# DataBinder.Eval(Container.DataItem,"Clicks")%></td>
				<td width="20"><%# DataBinder.Eval(Container.DataItem,"Sales")%></td>
			</tr>
		</table>
	</ItemTemplate>
	<FooterStyle HorizontalAlign="Right" ForeColor="#003399" BackColor="#E3E3E3"></FooterStyle>
	<HeaderStyle Font-Bold="True" Height="26px" ForeColor="#CCCCFF"></HeaderStyle>
</asp:datalist>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?