One suggestion.

Don't put subview in your included fragment.
Instead use it around your jsp:include.

<f:subview id="loginFrame">
   <jsp:include page="inc/loginframe.jsp" />
</f:subview>

This will prevent duplicate id problems as you can give each include a
different subview id.

I don't see why this would make any difference to your problem, though.


On 9/6/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
Hello

If I include the jsp the form is not rendered around the table.
Watch the JPG file.
If I call direct loginframe.faces everything is correctly
rendered.

Urs

The code

1) Include statement in other jsp files.

<jsp:include page="inc/loginframe.jsp" />

2) the loginframe.jsp content is

<%@ taglib uri="http://java.sun.com/jsf/html"; prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core"; prefix="f"%>
<%@ taglib uri="http://myfaces.apache.org/tomahawk"; prefix="t"%>
<f:subview id="loginFrame">
<h:outputText value="Herzlich willkommen #{websession.username}"
        rendered="#{websession.loggedIn}" />
<h:form rendered="#{!websession.loggedIn}">
        <table border="0" cellspacing="0" class="frame">
                <tr>
                        <td colspan="2" class="frametitle"><h:outputText
                                value="#{login.loginTitle}" /></td>
                </tr>
                <tr>
                        <td colspan="2"><t:messages /></td>
                </tr>
                <tr>
                        <td class="framelabel"><h:outputLabel for="username"
                                value="#{login.usernameLabel}" styleClass="loginlabel" 
/></td>
                        <td class="frameinput"><h:inputText id="username"
                                value="#{login.username}" required="true" size="15" 
/></td>
                </tr>
                <tr>
                        <td class="framelabel"><h:outputLabel for="password"
                                value="#{login.passwordLabel}" styleClass="loginlabel" 
/></td>
                        <td class="frameinput"><h:inputSecret id="password"
                                value="#{login.password}" required="true" size="15" 
/></td>
                </tr>
                <tr>
                        <td colspan="2" class="framebutton"><h:commandButton 
id="
loginButton"
                                action="#{login.login}" value="#{login.loginLabel}" 
/></td>
                </tr>
                <tr class="framerow">
                        <td colspan="2" class="framelink"><h:commandLink
                                action="#{register.register}" 
value="#{login.doRegisterText}"
/></td>
                </tr>
        </table>
</h:form>
</f:subview>


Reply via email to