<%@page contentType="text/html;charset=UTF-8" pageEncoding="ISO-8859-1" session="true"
%><%@page errorPage="Exception.jsp"
%><%@page import="com.fujitsu.iflow.model.bpm.BPMSession"
%><%@page import="com.fujitsu.iflow.model.workflow.WFObjectFactory"
%><%@page import="com.fujitsu.iflow.model.workflow.Plan"
%><%@page import="com.fujitsu.iflow.model.workflow.ProcessInstantiator"
%><%@page import="com.fujitsu.iflow.model.workflow.WorkItem"
%><%@page import="java.util.Enumeration"
%><%@page import="com.fujitsu.iflow.model.util.URLEncoder"
%><%
    request.setCharacterEncoding("UTF-8");request.getParameterNames(); //Need dummy call for WL9.1
    BPMSession bps = (BPMSession) session.getAttribute("BPMSession");
    if (bps == null) {
        %><jsp:include page="PasswordPanel.jsp" flush="true"/><%
        return;
    }
    String[] bcolor = {"evenrow","oddrow"};
    int nextColor = 0;
    session.setAttribute("TabIndex","-1");
%>
<html>
<head><title>Interstage Business Process Manager | Import BPEL</title>
<jsp:include page="StyleSheet.jsp" flush="true"/>
<script language="javascript" src="styles/clockscripts.js"></script>

<script language="javascript">
function validateFields()
{
    if (document.bpelForm.document.value == "")
    {
        alert("Please enter a valid file path.");
        document.bpelForm.document.focus();
        return false;
    }
}
</script>

</head>
<body class="bodyClass" onLoad="goforit();">
<jsp:include page="Header.jsp" flush="true"/>
<br/><br/>
<form name="bpelForm" enctype="multipart/form-data" method="post" action="ImportBPELAction.jsp" onSubmit="return validateFields()">
<center>
<TABLE border="0" cellpadding="4" cellspacing="1" bgcolor="#CCCCCC" class="tableClass" width="450">
    <tr>
        <td style="filter:progid:DXImageTransform.Microsoft.Gradient(startColorStr='#FFFFFF', endColorStr='#6699CC', gradientType='1'"><b>Importing BPEL File</b></td>
    </tr>
    <tr>
            <td bgcolor="#FFFFFF" align="center"><br/> BPEL File:
            <input type="file" name="document" width="300"><br/><br/>
            </td>
    </tr>
    <tr>
        <td valign="middle" align="center" bgcolor="#EEEEEE">
        <input type="submit" value="Import" class="submitClass">
        </td>
    </tr>
</table>

</center>
</form>
</body>
</html>