Count Lines in Pages

Contents of Page: Display_Menu_Buttons.asp Number of Lines: 149 Last Modified: 2/20/2026 8:18:08 AM
0001: <%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
0002: 
0003: <!--#include file="include/constants.inc"-->
0004: <!--#include FILE="include/adovbs.inc" -->
0005: 
0006: <%
0007: 
0008: 	XParentID = Trim(Request.QueryString("ParentID"))
0009: 	
0010: 
0011: 	
0012: 		Set rs = Server.CreateObject("ADODB.Recordset")
0013: 		
0014: If xParentID <> "" Then	
0015: 	
0016: 		sqlString = "SELECT * FROM mmMenu "	& _
0017: 							"WHERE ParentID = " & XParentID & " " & _
0018: 							"AND ImageID <> '' " & _
0019: 							"ORDER by NodeID "
0020: 							
0021: Else							
0022: 		
0023: 	sqlString = "SELECT * FROM mmMenu "	& _
0024: 							"WHERE Type <> 'z' " & _
0025: 							"AND ImageID <> '' " & _
0026: 							"ORDER BY ParentID, NodeID "
0027: 							
0028: End If	
0029: 	
0030: 	rs.Open sqlString, conn, adOpenDynamic, adLockOptimistic, adCmdText
0031: 	
0032: %>
0033: 
0034: <html>
0035: <head>
0036: <title>Chino DES - Navigation Menus Update</title>
0037: 	<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
0038: 	<link href="mm.css" rel="stylesheet" type="text/css">
0039: 	<link href="https://mychinodes.org/desb.css" rel="stylesheet" type="text/css">		
0040: 	<link href="https://mychinodes.org/des.css" rel="stylesheet" type="text/css">		
0041: 	<script language="JavaScript" type="text/javascript">
0042: 		function deleteNode(id,ParentID)	{
0043: 			if (!confirm("Are you sure you want to delete this node?"))	{
0044: 				return;
0045: 			}
0046: 			window.location = "DESMenuDelete.asp?id="+id+"&ParentID="+ParentID;
0047: 		}
0048: 	</script>
0049: </head>
0050: 
0051: <body bgcolor="#ffffff">
0052: 
0053: 		<table border="0" cellpadding="0" cellspacing="0" width="900">
0054: 															<td class="smalldark" align="LEFT" colspan="5">
0055: 									<button class="button-40" onclick="window.location.href = 'DESMenuEdit.asp?id=0&ParentID=<%= XParentID %>';"><small>Add New </button>
0056: 								</td>
0057: 								<td class="smalldark" align="LEFT" colspan="5">
0058: 								
0059: 								<button class="button-40" onclick="window.location.href = 'DES_Menu_Maint.asp';"><small>Show All Menu Entries</button>
0060: 								<button class="button-40" onclick="window.location.href = 'Display_Menu_Buttons.asp';"><small>Show Buttons</button></td>>	
0061: <% IF XParentID <> "" Then %>
0062: <td class="norm">Editing for ParentID: <big><%= XParentID %></td>
0063: <% End If %>								
0064: 						</tr>
0065: 			<tr>
0066: 				<td>
0067: 						<tr bgcolor="#C46488" height="30">
0068: 							<td class="small" align="center" width="3%">
0069: 								ID</td>						
0070: 							<td class="small" align="center" width="3%">
0071: 								Node</td>
0072: 							<td class="small" align="center" width="3%">
0073: 								Parent</td>
0074: 
0075: 							<td class="small" align="center" width="3%">
0076: 								Del</td>
0077: 							<td class="small" align="center" width="3%">
0078: 								Type</td>
0079: 							
0080: 							<td class="norm"  width="20%">
0081: 								Node Name</td>						
0082: 
0083: 
0084: 							<td class="norm"  width="20%">
0085: 								URL Address</td>	
0086: 							<td class="norm"  width="10%">
0087: 								Button</td>		
0088: 							<td class="norm"  width="30%">
0089: 								Button Format</td>	
0090: 
0091: 						</tr>
0092: 			<% 			bgcolor = "#ffeeee"
0093: 			trbgcolor = "#A4A4A4"
0094: 			LastParentID = ""
0095: 					Do Until rs.EOF
0096: 					ParentID = rs("ParentID").Value
0097: 
0098: 					If LastParentID = "" Then
0099: 					LastParendID = ParentID
0100: 					End If
0101: 					If LastParentID <> ParentID Then
0102: 					   	LastParentID = ParentID
0103: 						If bgcolor = "#A4A4A4" Then
0104: 							bgcolor = "#ffffff"
0105: 						Else
0106: 								bgcolor = "#A4A4A4"
0107: 						End If	
0108: End If		%>
0109: 						<tr bgcolor="<%= bgcolor %>" height="22">
0110: 							<td class="normBOLD" align="center" height="17">
0111: 								<a href="DESMenuEdit.asp?id=<%= rs("ID").Value %>&ParentID=<%= XParentID %>"><%= rs("ID").Value %></a></td>
0112: 														
0113: 						<td class="norm" align="center" height="17">
0114: 								<%= rs("NodeID").Value %></td>
0115: 							<td class="norm" align="center"><a href="Display_Menu_Buttons.asp?ParentID=<%= ParentID %>">
0116: 								<%= ParentID %></a></td>
0117: 
0118: 	
0119: 
0120: 							<td class="norm" align="center">
0121: 								<a href="javascript:deleteNode('<%= rs("ID").Value %>','<%= XParentID %>')" class="smallblueUndl">Del</a></td>	
0122: 							<td class="norm" align="center">
0123: 								<%= rs("Type").Value %></td>
0124: 							<td class="smalldark" align="left">
0125: 								<%= rs("NodeName").Value %></td>
0126: 
0127: 							<td class="smalldark" align="left">
0128: 								<%= rs("Link").Value %></td>
0129: 	
0130: 							<td class="smalldark" align="left">
0131: 								<%= rs("ImageID").Value %></td>
0132: 							<td>	
0133: 
0134: 								<button class="<%= rs("ImageID").Value %>" onclick="window.open('<%= rs("Link").Value %>','_blank');"><small><%= rs("NodeName").Value %></button>	
0135: 							</tr>
0136: 			<%		rs.MoveNext
0137: 					Loop
0138: 					rs.Close
0139: 					Set rs = Nothing	%>
0140: 						<tr>
0141: 							<td class="smalldark" align="center" colspan="7">
0142: 								<a href="DESMenuEdit.asp?id=0" class="normundl">Add New Menu Entry</a></td>
0143: 						</tr>
0144: 				</td>
0145: 			</tr>
0146: 		</table>
0147: 
0148: </body>
0149: </html>