JSP 페이지와 Javascript를 사용하는 인터페이스에서 작업 중입니다. 내 프로젝트 구조가 여기에 표시됩니다. 뷰에서 내 주요 JSP 페이지 (veditor.jsp
)에서iframe에서 jsp 페이지 호출
, 나는 속성 패널 부문이있다.
veditor.jsp
...
<!--Container/Canvas-->
<div id="container" class="container">
</div>
<!--Properties Panel-->
<div style="float: left" class="property" id="propertypane">
<h1 class="toolbox-titlex" id="toolbox-titlex">Properties</h1>
<iframe class = "panel" id="lot"></iframe>
</div>
...
여기에 내가 veditor.js
자바 스크립트를 사용하여 속성 패널에 veditor.jsp
의 iframe을 내 selectClauseForm.jsp
페이지를 호출해야합니다. 나는이 (가) callSelectForm()
메소드 내 경고하지만, 속성 패널이로드되지 않고 다음과 같은 오류를 얻고 둘을 얻고있다
if (dropElem == "stream ui-draggable") {
var newAgent = $('<div>').attr('id', i).addClass('streamdrop');
var elemType = "table";
$("#container").addClass("disabledbutton");
$("#toolbox").addClass("disabledbutton");
$('#container').append(newAgent);
callSelectClauseForm();
}
function callSelectClauseForm()
{
alert("Called before");
document.getElementById("lot").src = 'selectClauseForm.jsp';
alert("Called after");
}
는 veditor.js. 위와 같이 createTableForm(...)
메소드를 호출 할 때
는, I는 veditor.jsp
에 Iframe에 내 selectClauseForm.jsp
를 호출 할 필요가있다.
내 경로가 src
위치에 잘못 되었기 때문에이게 맞습니까? Javascript를 사용하여 iframe 내부에서 jsp를로드하는 방법에 대한 제안 사항은 새로운 것이므로 크게 감사하겠습니다.