나는 iframe이 onclick 함수에 의해 동적으로로드되는 시나리오가 있습니다.iframe 내부의 아코디언
iframe 내부에서 accordion을 사용하려고하지만 accordion()
기능이 작동하지 않습니다. 다음은
$(function() {
$("#accordion").accordion();
});
모든 솔루션이 무엇입니까?
iframe이 코드 : 나는 parent.html에 JQuery와 &에게 JQuery와 - UI 파일을 추가 한
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<script>
$(function() {
$("#accordion").accordion();
});
</script>
</head>
<body>
<% ApplicationBean app= (ApplicationBean)request.getAttribute("app");%>
<c:out value="${app.getAppName()}"/>
<div id="accordion">
<h3>Application</h3>
<div>
<p></p>
<table>
<tr>
<td>Application Name</td>
<td><c:out value="${app.getAppName()}"/></td>
</tr>
<tr>
<td>Service URL</td>
<td><c:out value="${app.getServiceUrl()}"/></td>
</tr>
<tr>
<td>Deploy Time</td>
<td><c:out value="${app.getDeployTime()}"/></td>
</tr>
<tr>
<td>Status</td>
<td>
<c:choose>
<c:when test="${app.isRunning()==true}">Running</c:when>
<c:otherwise>Down</c:otherwise>
</c:choose>
</td>
</tr>
<tr>
<td>WSDL</td>
<td>
<c:out value="${app.getWsdls() }"></c:out>
</tr>
</table>
</div>
<h3>Libraries</h3>
<div>
<p></p>
</div>
<h3>Message Flows</h3>
<div>
<p></p>
</div>
</div>
는
당신은 테이블의 마지막 TD에서''끝이없는 – littleLouito
는 여전히 도움 – user153
않았다 iframe이 내부에로드 된 페이지에서 JQuery와 및 JQuery와 - UI를 추가,하지만 난해야한다 그게 문제라고 생각하지 마시오 – littleLouito