调用接口,需要拼接SOAP包,访问页面的时候不要写localhost,这样会引起跨域的问题,访问不了。
这个jsp页面包括了根据下拉框选择,变更不同的输入条件,用到了jquery的一些文档操作方法。
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<title>导入导出功能</title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<jsp:include page="/common/common.jsp"></jsp:include>
<link rel="stylesheet" rev="stylesheet" type="text/css" href="${pageContext.request.contextPath}/skin/default/css/default.css" media="all"/>
<script language="javascript" src="${pageContext.request.contextPath}/js/common.js"></script>
</head>
<body>
<form id="loginform" method="post">
<div class="textbox" id="centerTextbox">
<div class="textbox-header">
<div class="textbox-inner-header">
<div class="textbox-title">
<h1> 元数据信息WebService</h1>
</div>
</div>
</div>
<div class="textbox-header">
<div class="textbox-inner-header">
<div class="textbox-title">
<table id="insertinto" class="commonTable" cellspacing="1">
<tr>
<td class="columnTitle_mustbe">用户名:</td>
<td class="tableContent"><input type="text" id="auth_id"/></td>
<td class="columnTitle_mustbe">密码:</td>
<td class="tableContent"><input type="password" id="auth_pwd"/></td>
</tr></table>
<hr><br>写入数据
</div>
</div>
</div></form>
<form id="writeform" method="post">
<div>
<div>
<table id="insertinto" class="commonTable" cellspacing="1">
<tr>
<td class="columnTitle_mustbe">应用范围:</td>
<td class=