I am having a jsp page on which am trying to show a button depending on my variable flag.
If flag=0 then i want to have a submit ADD button but if flag is set to 1 then i want to have a disabled REQUEST SEND button and other button should not be shown while other is been shown.
Here is my jsp code part :
<%
String groupidd = request.getSession().getAttribute("groupid").toString();
s=null;
rs=null;
int flag=0;
String sql="select * from TBGROUPUSERS where I_ID=? and GU_GROUPID=?";
s = con.prepareStatement(sql);
s.setString(1,idperson);
s.setString(2,groupidd);
rs=s.executeQuery();
if(rs.next())
flag=1;
%>
Now based on this flag value how i can do this ?