当用户点击图像时,如何从datalist显示其他页面中产品的特定细节 [英] How to display Particular detail of product in other Page from datalist when user click on image

查看:46
本文介绍了当用户点击图像时,如何从datalist显示其他页面中产品的特定细节的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

< asp:DataList ID =DataList1runat =serverBackColor =GrayBorderColor =white

BorderStyle =NoneBorderWidth =0CellPadding =10 CellSpacing =12

字体名称=Verdana字体大小=小GridLines =两个RepeatColumns =4RepeatDirection =水平

宽度=600px>

< footerstyle backcolor =#F7DFB5forecolor =#8C4510>

< HeaderStyle BackColor =#333333 Font-Bold =True字体大小=大ForeColor =白色

Horizo​​ntalAlign =中心VerticalAlign =中间/>

< HeaderTemplate>

产品详细信息< / HeaderTemplate>

< itemstyle backcolor =Whiteforecolor =Blackborderwidth =2px>

< itemtemplate>

< asp:HyperLink ID =HyperLink1runat =serverPostBackUrl ='<%#WebForm3.aspx?PName =+ Bind( ProductName)%>'>

< asp:Image ID =imgProdrunat =serverWidth =250pxHeight =150pxImageUrl ='<%#绑定(ImageUrl)%>'style =padding-left:40px/>




产品名称:

< asp:Label ID =lblPNamerunat =serverText ='<%#Bind(ProductName)%>'>






价格:

< asp:标签ID =lblNamerunat =服务器Text ='<%#Bind(Price)%>'>




描述:

< asp:Label ID =lblDesrunat =serverText ='<%#Bind(Description)%>'>

< br>



< asp:标签ID =lblPIDrunat =serverVisible =falseText ='<%#Bind(ProductID )%>'>






< asp:标签ID =lblCIDrunat =serverVisible =falseText ='< %#Bind(CategoryID)%>'>












先生,我在asp.net.i创建在线购物已经在datalist中显示产品项目

和现在如何显示特定产品图像和细节当我点击产品图片

<asp:DataList ID="DataList1" runat="server" BackColor="Gray" BorderColor="white"
BorderStyle="None" BorderWidth="0" CellPadding="10" CellSpacing="12"
Font-Names="Verdana" Font-Size="Small" GridLines="Both" RepeatColumns="4" RepeatDirection="Horizontal"
Width="600px">
<footerstyle backcolor="#F7DFB5" forecolor="#8C4510">
<HeaderStyle BackColor="#333333" Font-Bold="True" Font-Size="Large" ForeColor="White"
HorizontalAlign="Center" VerticalAlign="Middle" />
<HeaderTemplate>
Product Detail</HeaderTemplate>
<itemstyle backcolor="White" forecolor="Black" borderwidth="2px">
<itemtemplate>
<asp:HyperLink ID="HyperLink1" runat="server" PostBackUrl='<%#"WebForm3.aspx?PName="+ Bind("ProductName") %>'>
<asp:Image ID="imgProd" runat="server" Width="250px" Height="150px" ImageUrl='<%# Bind("ImageUrl") %>' style="padding-left:40px"/>


Product Name:
<asp:Label ID="lblPName" runat="server" Text='<%# Bind("ProductName") %>'>



Price:
<asp:Label ID="lblName" runat="server" Text='<%# Bind("Price") %>'>


Description:
<asp:Label ID="lblDes" runat="server" Text=' <%# Bind("Description") %>'>



<asp:Label ID="lblPID" runat="server" Visible="false" Text='<%# Bind("ProductID") %>'>



<asp:Label ID="lblCID" runat="server" Visible="false" Text='<%# Bind("CategoryID") %>'>






Sir,I m creating online shopoping in asp.net.i have already display product items in datalist
and Now How to Display Particular Product Images and detail When i will click On product Image

推荐答案

这篇关于当用户点击图像时,如何从datalist显示其他页面中产品的特定细节的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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