Nicola Ken Barozzi wrote:
Ross Gardler wrote:
Tim Williams wrote:
...
It sounds like Cocoon's "Views" would be more appropriate, allowing
you to do something like this:
http://domain.com/resume/blogs.html?view=complete
http://domain.com/resume/blogs.html?view=summary
Your use-case sounds a lot like the description of cocoon views. Maybe
you're not going that route for a reason though?
Using a parameter in the URL is not an option since these do not make
for valid filenames and therefore it is impossible to generate a static
site (a requirement in this use case).
...
You see, ultimately, I would like to be able to provide a parameterised
template that would allow *users* to specifiy what is in their view by
editing a config file. I'm just working out where the best palce to do
this is. Prior to forrest:views I would, without hesitation, have done
it in the sitemap. Now I can see that it may be possible in
forrest:views (I'm not saying this is the right thing to do though).
We already had this discussion (without the views implication part).
In practice, pdf output, text output, html output, etc are different
"views" already, and they differentiate only for the extension.
This can and should be generalized, also because in an ideal web, there
would be no extension, just a request that is given the best content
given the client capabilities.
The result was that to specify manually the output type, the name of the
file would have to change, in a way similar to what is used by Apache
HTTPD for multilingual sites.
Damn, I don't remember the thread, but we had come up with a decision on
how to define the filename. Rats.
I recall the discussion. You are right what I am proposing here could
also be applied to that problem, although the use case here is different
since it is the content not the output format that changes.
In another mail Thorsten suggested a hack for this that will work with
no code modification. It's worth considering this hack as a solution to
the "extension" problem described in the discussion in our archives.
I don't have the time to find that discussion right now. Anyone have a
clearer recollection to be able to search for it quickly (my first few
attempts failed so it's back to the deadline beating)...
Ross