You can name the files whatever you want, but it must allow the
FacesServlet to be invoked (so make sure your ServletMapping matches).
The "viewId" that is given is treated as a filename relative to the
docroot (or in a jar file).
NOTE: Some older versions of JSF had a bug where they modified the
viewId so that information was lost -- namely the extension. This
limited the file name to whatever the default extension is set to --
.jsp if you haven't changed it. The JSFTemplating project still is
able to use .jsf even w/ these broken versions.
The .dtd error you're getting is b/c the file is being recognized as an
XML file (by the XMLLayoutDefinitionManager) but it is not a proper
JSFTemplating XML file. I suggest *not* using the XML syntax for
JSFTemplating unless you have a strong need to do so. The other syntax
is much simpler. Try a file named "hello.jsf" with the contents:
"Hello!
The XML equivalent is several lines long.
If you want to use a different extension, like ".abc"... you can modify
your web.xml to map .abc requests through the FacesServlet. Then name
your files .abc. If it doesn't work, you have a broken version of JSF...
you'll need to change the default JSF extension by setting a Servlet
init parameter named "javax.faces.DEFAULT_SUFFIX" to "abc".
Ken
Todd Patrick wrote:
> (Ken - I'll respond the other emails after this.)
>
> Back to step 1 - I went through the tutorial and found that the pages
> must be named <label>.jsf?
>
> I had labeled the page <label>.jsp and tried to call it in the browser
> <label>.jsf, this returned an error:
>
> The system cannot locate the object specified. Error processing resource
> 'http://127.0.0.1:8080/jsftemplating/layout.dtd'.
>
> Why must the actual file names end with the .jsf suffix?
>
> Thanks,
>
> --Todd
>