I found some info in the archives of the mailing list:
http://mail-archives.apache.org/mod_mbox/tapestry-users/200704.mbox/% [EMAIL PROTECTED]

However, I don't understand the fix:
"Layout is a component, not a page.  It goes into the components
package.  So Layout.java needs to be in foo.bar.components, and so
does Layout.html."

I have my Layout.java in the right location, but this is the first I've heard of a components directory for the html part of components. Is there also a pages directory for the html part of pages? I don't have one and pages seem to work fine.

What would the path be for the components html directory? Mine is currently at:
project/webapp/WEB-INF/.
My pages html files are here too.

R


On Oct 3, 2007, at 4:27 PM, Robert A. Decker wrote:

I'm trying to create the simple layout component described here:
http://tapestry.apache.org/tapestry5/tapestry-core/guide/ templates.html
(I've also read the wiki info on components)

But I'm getting an exception:
java.lang.IllegalStateException
This markup writer does not have a current element. The current element is established with the first call to element() and is maintained across subsequent calls.


I've created Layout.html in the same location my Start.html file is at:

<html xmlns:t="http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";>
    <head>
        <title>Title</title>
    </head>
    <body>
        <t:body/>
    </body>
</html>


I've also created Layout.java in com.company.project.components:

package com.company.project.components;
public class Layout {

}


And I have a file name Main.html that the user is sent to after successfully logging in:

<t:layout xmlns:t="http://tapestry.apache.org/schema/ tapestry_5_0_0.xsd">

  Page Specific Content

</t:layout>




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to