Question : Lightbox problem in asp.net/vb.net

I am having problems using a lightbox in asp.net/vb.net, it always shows all images vertically when clicking on one of the images, as one can see at http://sul.algarveweb.com/Property/Apartment/A271.aspx.

Page Code (working fine):
1:
<a style="text-decoration: none;" href="<%# GetAttachmentUrl(Eval("AttachmentName"), Eval("NodeAliasPath")) %>" rel="lightbox[attachments]" rev="<%# Eval("AttachmentID") %>" title="<%# Eval("AttachmentName", true) %>"><img style="border: none;" src="<%# IfCompare(ImageHelper.IsImage(Eval("AttachmentExtension").ToString), 0, GetAttachmentIconUrl(Eval("AttachmentExtension"), Nothing), GetAttachmentUrl(Eval("AttachmentName"), Eval("NodeAliasPath"))) %>?maxsidesize=150" alt="<%# Eval("AttachmentName", true) %>" /></a>


Popup Code(not working):
1:
<%#IfCompare(ImageHelper.IsImage(Eval("AttachmentExtension").ToString), 0, "<div style='text-align: center; width: 350px;'><div style='font-size: 11px;line-height: 12px; position: relative; z-index:1000; margin: auto; width: 140px;'><a target='_blank' href='" + GetAttachmentUrl(Eval("AttachmentName"), Eval("NodeAliasPath")) + "'><img style='border: none;' src='" + GetAttachmentIconUrl(Eval("AttachmentExtension"), Nothing) + "' alt='" + Eval("AttachmentName") + "' /></a><p>" + ResHelper.GetString("attach.openfile") + "</p></div></div>", "<img src='" + GetAttachmentUrl(Eval("AttachmentName"), Eval("NodeAliasPath")) + "?maxsidesize=500' alt='" + Eval("AttachmentName", True) + "' />")%>


Answer : Lightbox problem in asp.net/vb.net

for pop up code  you have given,

i found that you have not added -

rel="lightbox[attachments]"

which is important for lightbox.

try by adding same.
Random Solutions  
 
programming4us programming4us