Commit 16fc1abe authored by 赵桢's avatar 赵桢

修改

parent 18eebe34
...@@ -63,47 +63,24 @@ ...@@ -63,47 +63,24 @@
<%--<script src="<%=request.getContextPath()%>/res/js/education/config.js"></script>--%> <%--<script src="<%=request.getContextPath()%>/res/js/education/config.js"></script>--%>
<script src="<%=request.getContextPath()%>/res/js/education/config.js"></script> <script src="<%=request.getContextPath()%>/res/js/education/config.js"></script>
<script> <script>
$(document).ready(function () { $(document).ready(function (){
var baseUrl = getBaseUrl(); var baseUrl = getBaseUrl();
console.log('baseUrl = ',baseUrl) //获取token里面的内容
// 获取 token 里面的内容
<% <%
Cookie[] cookies = request.getCookies(); Cookie[] cookies = request.getCookies();
String SESSION = ""; String SESSION = "";
for (int i = 0; i < cookies.length; i++) { for(int i = 0; i < cookies.length; i++) {
if ("SESSION".equals(cookies[i].getName())) { if ("SESSION".equals(cookies[i].getName())) {
SESSION = cookies[i].getValue(); SESSION = cookies[i].getValue();
} }
} }
request.setAttribute("SESSION", SESSION); request.setAttribute("SESSION", SESSION);
%> %>
<%--console.log('---- ',<%=request.getAttribute("SESSION")%>)--%> var url=baseUrl + "?session=<%=request.getAttribute("SESSION")%>"
var url = baseUrl + "?session=" + <%=request.getAttribute("SESSION")%>; // alert(url)
var iframe=$('<iframe width="100%" height="100%" src="'+url+'"></iframe>')
// console.log('url = ',url) $("#iframe").append(iframe)
// 显示 url })
// alert(url);
var iframe = $('<iframe width="100%" height="100%" src="' + url + '"></iframe>');
$("#iframe").append(iframe);
});
<%--$(document).ready(function (){--%>
<%-- //获取token里面的内容--%>
<%-- <%--%>
<%-- Cookie[] cookies = request.getCookies();--%>
<%-- String SESSION = "";--%>
<%-- for(int i = 0; i < cookies.length; i++) {--%>
<%-- if ("SESSION".equals(cookies[i].getName())) {--%>
<%-- SESSION = cookies[i].getValue();--%>
<%-- }--%>
<%-- }--%>
<%-- request.setAttribute("SESSION", SESSION);--%>
<%-- %>--%>
<%-- var url="http://localhost:8081?session=<%=request.getAttribute("SESSION")%>"--%>
<%-- // alert(url)--%>
<%-- var iframe=$('<iframe width="100%" height="100%" src="'+url+'"></iframe>')--%>
<%-- $("#iframe").append(iframe)--%>
<%--})--%>
</script> </script>
<div class="modal fade" id="loadingModal" backdrop="static" keyboard="false"> <div class="modal fade" id="loadingModal" backdrop="static" keyboard="false">
  <div style="width: 200px;height:20px; z-index: 20000; position: absolute; text-align: center; left: 50%; top: 50%;margin-left:-100px;margin-top:-10px">   <div style="width: 200px;height:20px; z-index: 20000; position: absolute; text-align: center; left: 50%; top: 50%;margin-left:-100px;margin-top:-10px">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment