1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
|
<%@ page import="java.util.*,java.net.*,java.text.*,
com.eteks.forum.*,com.eteks.outils.*" errorPage="erreur.jsp" %>
<%@ include file="connecteurforum.jsp" %>
<html>
<head> <title> Forum : Accueil </title> </head>
<body> <center> <h1> Forum </h1>
<jsp:include page="/WEB-INF/navigation.jsp"/><br>
<table border="1" cellpadding="2" cellspacing="0" with="90%">
<tr bgcolor="#9999CC" align="center">
<td> <b> Sujet</b> </td>
<td> <b> Dernier message</b> </td>
</tr>
<%EnsembleMessageForum sujets = new EnsembleMessageForum();
sujets.rechercheSujets(connecteurForum);
DateFormat dateFormat = DateFormat.getInstance();
int ligne= 0;
For (Iterator it=sujets.iterator(); it.hasNext();
{
MessageForum sujet=(MessageForum)it.next(); %>
<tr bgcolor="<%= ligne++ % 2==0 ? "#FFFFFF" : "#CCCCCC" %>">
<td><a href="<%= "liresujet.jsp?sujet="
+URLEncoder.encode(sujet.getSujet(), "ISO-8859-1")%>">
<%OutilChaine.convEnHtml(sujet.getSujet()) %> </a> </td>
<td align="center"> <%= dateFormat.format(
sujet.getDateCréation())%></td>
</tr>
<% } %>
</table>
</center>
</body>
</html> |
Partager