%@ page language="java" %>
<%@ page import="com.xoomers.util.*" %>
<%@ page import="com.xoomers.db.*" %>
<%
Boolean auth=(Boolean)request.getSession(true).getAttribute("authenticated");
if (auth==null ||!(auth.booleanValue())) { %>
User Information
Username: <%= user %>
Group: <%= group %>
Points: <%= points %>
Contests [Propose Contest]
<%
r = null;
try {
r = db.query(
"select contests.id,games.name"+
" from contests,games"+
" where contests.type = 3 and"+
" (contests.togid ="+gid+
" or contests.fromgid ="+gid+
") and games.id = contests.game"
);
} catch( Exception e ) {
System.out.println(e);
e.printStackTrace();
}
%>
| "+r.getString(1)+" | "); if( scored > 0 ) out.println("[Scored] | [Post Score] | "); } else { out.println("
| "+r.getString(1)+" | "); if( scored > 0 ) out.println("[Scored] | [Post Score] | "); } } %>
Challenges
<%
r = null;
try {
r = db.query(
"select contests.id,games.name,contests.fromgid"+
" from contests,games"+
" where contests.type = 2 and "+
" togid ="+gid+
" and games.id = contests.game"
);
} catch( Exception e ) {
System.out.println(e);
e.printStackTrace();
}
%>
| "+r.getString(1)+" | "); if( voted > 0 ) out.println("Voted | [Vote] | "); } else { out.println("
| "+r.getString(1)+" | "); if( voted > 0 ) out.println("Voted | [Vote] | "); } } %>
Proposals
<%
r = null;
try {
r = db.query(
"select contests.id,games.name,contests.togid"+
" from contests,games"+
" where contests.type = 1 and "+
" fromgid ="+gid+
" and games.id = contests.game"
);
} catch( Exception e ) {
System.out.println(e);
e.printStackTrace();
}
%>
| "+r.getString(1)+" | "); if( voted > 0 ) out.println("Voted | [Vote] | "); } else { out.println("
| "+r.getString(1)+" | "); if( voted > 0 ) out.println("Voted | [Vote] | "); } } %>
Messages [Post Message]
<%
r = null;
try {
r = db.query("select id,postdate,subject from messages where gid ="+gid);
} catch( Exception e ) {
System.out.println(e);
e.printStackTrace();
}
%>
| Subject | Date |
|---|---|
| "+ ""+ r.getString(2)+" | "+ ""+d+" |
| "+ ""+ r.getString(2)+" | "+ ""+d+" |