<% Set rsAwardID = Server.CreateObject("ADODB.Recordset") rsAwardID.ActiveConnection =con_string rsAwardID.Source ="SELECT DISTINCT Photo_Gallery.Photo_Category, Gallery_Category.id, Gallery_Category.Category_Name AS galleryname, Gallery_Category.vieworder FROM Gallery_Category RIGHT JOIN Photo_Gallery ON Gallery_Category.ID = Photo_Gallery.Photo_Category ORDER BY Gallery_Category.vieworder;" rsAwardID.CursorType = 0 rsAwardID.CursorLocation = 2 rsAwardID.LockType = 1 rsAwardID.Open() %>

» <%=pagename%>

Please click the name to view the galleries


<%do while not rsAwardId.eof%>

 <%=rsAwardID("galleryname")%>

<% Set rsGalleryItems = Server.CreateObject("ADODB.Recordset") rsGalleryItems.ActiveConnection = con_string rsGalleryItems.Source ="SELECT Photo_Gallery.ID, Photo_Gallery.Photo_file,Photo_Gallery.Thumb_file, Photo_Gallery.Photo_Category, Photo_Gallery.Photo_Title FROM Photo_Gallery WHERE (((Photo_Gallery.Photo_Category)="&rsAwardID("id")& "));" rsGalleryItems.CursorType = 0 rsGalleryItems.CursorLocation = 2 rsGalleryItems.LockType = 1 rsGalleryItems.Open() %>
<%rsAwardId.movenext%> <%loop%>

Collapse all | Expand all