checkbox select a group
I have the following good source code which works fine. The result is a page with some checkboxes that their values come from a db.
Now I would like to ask whether if I could change the style of checkboxes so that similar items that have the same root come togehter. What adjustments should I apply.
<html ><%@ page import = "java.sql.*,java.text.*,java.util.*,java.net.*,com.util.*,com.bipc.*" %>
<head>
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="keywords" >
<meta name="description" >
</head>
<link rel="stylesheet" type="text/css" href="images/style.css">
<body topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0" marginwidth="0" marginheight="0">
<% if (request.getParameter("close")!=null) {%><script> window.close();</script><% } %>
<table border="0" width="100%" id="table2" cellpadding="0" cellspacing="5">
<tr>
<td bgcolor="#FFFFFF" valign="bottom">
<p align="center">
<img border="0" src="images/farsititle.gif" align="bottom"><img border="0" src="images/logo_s.gif" width="47" height="36"></td>
</tr>
</table>
<font color="#808080">
<% int id=(request.getAttribute("id")==null)?0:Integer.parseInt((String)request.getAttribute("id")) ;%>
<span lang="fa">
<table dir="rtl" id="table1" style="BORDER-COLLAPSE: collapse" bgcolor="White"
borderColor="#ededed" cellSpacing="0" width="100%" border="1">
<form action="doEdit" name=form1><input type="hidden" name="actionType" value="permissionsave"><input type="hidden" name="id" value="<%=id%>">
<!-- Script -->
<script>
function doSave(){
document.form1.actionType.value="permissionsave";
document.form1.submit();
}
</script>
</span>
<tr>
<td vAlign="top" align="center" height="16" bgcolor="#92C9EB">
<span lang="fa"><font face="Tahoma" size="4" color="#FFFFFF">عنوان</font></span></td>
</tr>
<span lang="fa">
<%
ResultSet result=(ResultSet)request.getAttribute("result");
%><%int count=0;
int I=0;
int K=0;
while(result.next()) {%>
<tr>
<td align="left" height="16">
<p dir="ltr">
<font color="#808080">
<span lang="fa">
<input type=checkbox <%=(Permission.hasPermission(id,result.getInt("id")))?"checked":"" %> name="id<%=result.getString("id")%>" size="38" style="font-family: Tahoma; font-size: 11px; " dir="rtl"
></span></font><%=result.getString("name")%> (<%=result.getString("type_desc")%>) </font></font></span></td>
</tr>
<% } %>
<tr>
<td align="left" height="29">
<p align="center"><font color="#808080">
<a href="javascript :doSave();">
<img height="25" src="images/i_save_b.gif" border="0"></a></font></td>
</form>
</tr>
</span>
</span>
</font>
</table>
<p align="center"> </p>
</body>
</html>
Last edited by borna; Jul 15, 2006 at 04:59 .
Reason: More clarify
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Bookmarks