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
| <%@ page import="liste des imports..."%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
<%@ taglib uri="http://displaytag.sf.net" prefix="display" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>ISIOS - Import</title>
<link rel="stylesheet" href="css/panel.css" />
<link rel="stylesheet" href="css/worklist.css" />
<SCRIPT language="JavaScript">
function uploadFile(){
var formulaire = document.importForm;
alert(formulaire.tpsLink.value); // C'est ici que je voudrais récupérer le contenu de tpsLink pour écrire une instruction du type : if (formulaire.tpsLink.value == null){ alert("Sélectionnez quelque chose."); return false; }
if (formulaire.tpsLink.value==null) return false; // pour ne pas envoyer les informations à la servlet et rester sur la page courante
</SCRIPT>
<form name="importForm" enctype="multipart/form-data" method="post" action="ImportServlet">
<fieldset width=80%><legend accesskey=I><span class="b_form"> Informations générales</span></legend>
<table align="center">
<td><span class="b_form">Choix TPS & moteur calcul : * </span></td>
</table>
<div align="center" id="kbTable" name="kbTable">
<display:table id="table_tps" name="sessionScope.isiosExp_KnowledgeBases" export="false" class="workListTable">
<display:column title=" Choix " media="html" class="checkBox_col">
<acronym title="Ligne à selectionner choisir la base" lang="fr">
<input type="radio" name="tpsLink" value="<c:out value='${table_tps.id}'/>"/>
</acronym>
</display:column>
<display:column property="nameKnowledgeDataBase" title="TPS" sortable="false"></display:column>
<display:column property="tpsVersion" title="Version TPS" sortable="false"></display:column>
<display:column property="referenceKnowledgeDataBase" title="Référence" sortable="false"></display:column>
<display:column property="tempParamName" title="Paramètre" sortable="false"></display:column>
<display:column property="kbVersion" title="Version KB" sortable="false"></display:column>
<display:setProperty name="paging.banner.placement">bottom</display:setProperty>
<display:setProperty name="basic.empty.showtable">true</display:setProperty>
<display:setProperty name="basic.msg.empty_list">Aucun résultat.</display:setProperty>
</display:table>
</div>
</fieldset>
<table align="center">
<tr align="center">
<td colspan="3"><input type="button" onClick="uploadFile()" value="Importer" class="bouton"></td>
</tr>
</table>
</body>
</html> |
Partager