Click here to Skip to main content
15,883,883 members
Please Sign up or sign in to vote.
1.80/5 (2 votes)
See more:
Posted
Comments
[no name] 17-Feb-14 7:00am    
can you improve your question, so that i can help you.
Member-2338430 17-Feb-14 7:08am    
<div class="hover-box" id="Etkinlik" runat="server">



</div>
this is my tag
I want to do 4 images I have in database I get with httphandler but div has 1 tag so one images coming
I think codebehind
tag I can duplicate inside the div how can I send 4 times with different id number to httphandler

System.Web.UI.HtmlControls.HtmlGenericControl createDiv =
new System.Web.UI.HtmlControls.HtmlGenericControl("DIV");
createDiv.ID = "createDiv";
createDiv.Style.Add(HtmlTextWriterStyle.BackgroundColor, "Yellow");
createDiv.Style.Add(HtmlTextWriterStyle.Color, "Red");
createDiv.InnerHtml = "Div added from code behind ";
this.Controls.Add(createDiv);
 
Share this answer
 
XML
<div>
       <img alt="httpHandler" src="getImage.ashx?id=1">
   <img alt="httpHandler" src="getImage.ashx?id=2">
   <img alt="httpHandler" src="getImage.ashx?id=3">
   <img alt="httpHandler" src="getImage.ashx?id=4">
   </div>
 
Share this answer
 
Comments
Member-2338430 17-Feb-14 7:35am    
how can I do loop for ex 30 images I have I will write 30 line?
[no name] 17-Feb-14 7:43am    
no for this you can use this div in any data control i.e Repeater, datalist etc.
Member-2338430 17-Feb-14 8:46am    
I have 3 images in my page for ex animals trees teachers if you click animals image pop up open so animals slider coming so summary there is categorize these images comes from mysql database blob type so I must use httphandler because these images must convert there is no problem upto here but animals 4 images I have only one images coming
Member-2338430 17-Feb-14 8:47am    
how can I do repeater
like that ??

<div class="hover-box">
<asp:Repeater ID="Repeater" runat="server">
<itemtemplate>

<img class= "zoom" alt="httpHandler" src='<%# "../EtkinlikResimGetir.ashx?ImID=" + Eval("id")%>'>
<%----%>


</div>
XML
<div class="hover-box" id="Etkinlik" runat="server">

                                            <a class="zoom" href='<%# "../EtkinlikResimGetir.ashx?ImID=" + Eval("id")%>'></a>

                                        </div>



here only one tag so only one images coming from httphandler I wanto to duplicate a tag to send http handler
 
Share this answer
 
v2
Comments
Member-2338430 17-Feb-14 7:11am    
a tag I cant write
Sergey Alexandrovich Kryukov 30-May-14 18:10pm    
Not an answer. Did you self-accept this post as answer? Why? Both the post and accepting is is considered as abuse. Please don't do it.
—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900