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 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
| <%@ page language="java" pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-logic" prefix="logic" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-tiles" prefix="tiles" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-template" prefix="template" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-nested" prefix="nested" %>
<%@page import="java.io.BufferedReader"%>
<%@page import="java.io.InputStreamReader"%>
<%@page import="java.util.StringTokenizer"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html:html locale="true">
<head>
<link href="btn.css" type="text/css" rel="stylesheet"/>
<link href="table.css" type="text/css" rel="stylesheet"/>
</head>
<body>
<%
String cmd = "svn list svn://localhost";
StringTokenizer st=null;
try {
Runtime r = Runtime.getRuntime();
Process p = r.exec(cmd);
String s =null;
BufferedReader reader = new BufferedReader(new InputStreamReader(p.getInputStream()));
StringBuffer buffer = new StringBuffer();
while ((s = reader.readLine()) != null) {
buffer.append(s);
}
String result = buffer.toString();
st = new StringTokenizer(result,"/");
}
catch(Exception e)
{
System.out.println("erreur d'execution" + cmd + e.getMessage());
}
%>
<form method="get" action="supprimerP.do" name="supprimerP">
<table id="mytable">
<thead>
<tr>
<th>id projet</th>
<th>Project Name</th>
<th>Select</th>
</tr>
</thead>
<tfoot>
<tr>
<td><center><button type="button" class="statbtn" onclick="open('projetForm.jsp','new','width=500,height=380');">Add Project<img src="icons/add.png" alt=""/></button></center></td>
<td colspan="2"><center><button type="submit" class="statbtn">Erase Project<img src="icons/cross.png" alt=""/></button></center></td>
</tr>
</tfoot>
<tbody>
<tr>
<td>
<tr>
<%
int i=1;
while (st.hasMoreTokens()){
%>
<td><b><%=i%></b>
<% i++; %>
</td>
<td>
<%
out.println (st.nextToken());%>
<td><input type="checkbox" name="suppprojet" value="<%=i%>"/></td></tr>
<%}%>
</tbody>
</table>
</form>
</body>
</html:html> |
Partager