I have some problem with the update of a iframe inside a <c:forEach>
iterator:
<h:form>
<p:outputPanel rendered="#{dd.render()}">
<p:tabView dynamic="true">
<c:forEach var="aba" items="#{dd.abas}">
<p:tab title="#{aba.orelha}" >
<h2>
<h:outputText value="#{aba.titulo}" />
<p:selectOneMenu style="width:250px; float:right;" value="#{aba.ln}" rendered="#{aba.selecaoAtiva}">
<f:selectItems value="#{aba.itens}" />
<p:ajax update="WHAT SHOULD GO HERE???" event="change" />
</p:selectOneMenu>
</h2>
<f:view>
<iframe src="very-Boring-And-Long-E.L.-Built-URL" width="#{dd.largura}" frameborder="0" height="#{dd.altura}" />
</f:view>
</p:tab>
</c:forEach>
</p:tabView>
</p:outputPanel>
</h:form>
I want to update ONLY the iframe contents when the user selects something on the <p:selectOneMenu>
. The original code had @form
on the ajax tag, and was updating the whole form and putting the user back into the 1st tab.
How can I make the ajax update the iframe whithout messing with the active tab?