【发布时间】:2011-11-27 07:43:49
【问题描述】:
在我问我的问题之前,我已经经历了这个:Better alternative to an iframe?,并没有找到解决我问题的方法,或者我没有正确理解!
我有一个 HTML 页面,其中包含左侧的 Dojo 树。当我点击左侧树上的一个元素(比如 element1)时,我在右侧加载了一个带有 url 的 iframe:
www.something.com?selected=element1
现在框架的来源是一个执行此操作的jsp:
<%
/* Get the user selection*/
String selectedElement = request.getParameter("selected");
/* Code to Fetch some content from the database using the above string */
%>
由于左侧树有许多元素,单击每个元素会加载右侧的 iframe,如上所示。安排工作得很好。但我想知道这是否是最好的方法?我可以不使用 iframe 并且仍然获得相同的结果吗?我在某处读到加载 iframe 比不加载 iframe 慢几倍。 任何帮助将不胜感激!
【问题讨论】:
标签: javascript jsp iframe