Diwaker,
It does to some degree. I had found the foo.xml/foo.fv, default.fv
mapping and that helps immensely. I think the part that I'm not
understanding is the other <forrest:hook> bit.
Should that content be in another file and included somehow? I see, but
do not understand, how the leftbar is pieced together because forrest
generates it, specifically with the nav-section contract. I just tried
hacking the sitemap-contact.ft contract, calling it extra-info.ft and
placing this into index.fv:
<forrest:hook name="content">
<forrest:contract name="content-title"/>
<forrest:contract name="content-abstract"/>
<forrest:contract name="content-minitoc"/>
<forrest:contract name="content-main"/>
</forrest:hook>
<forrest:hook name="rightbar">
<forrest:contract name="extra-info"/>
</forrest:hook>
The content bit comes from your default.fv and I've added the extra-info
piece. The extra-info contract is a bit large and I don't know how much
stuff is normally posted to the list as far as code goes. The core part
of the template goes like this:
<xsl:stylesheet version="1.1"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template name="extra-info-body">
<xsl:if test="extra.xml">
<xsl:for-each select="extra.xml">
<xsl:comment>+
|start extra-info
+</xsl:comment>
<xsl:copy-of
select="[EMAIL PROTECTED]'content']/[EMAIL PROTECTED]'content-main']/*"/>
<xsl:comment>+
|end content-main
+</xsl:comment>
</xsl:for-each>
</xsl:if>
</xsl:template>
</xsl:stylesheet>
Where extra.xml is where I've stuffed the information for the third
column. Does this look like a valid approach where I just have some
syntax wrong, or have I completely missed what's supposed to be going on
here?
Thanks!
-Paul
Diwaker Gupta wrote:
On Sunday 31 July 2005 6:10 pm, CFAS Webmaster wrote:
Is anyone would be willing to help me through the process of making
this work properly? The original site that I'm trying to emulate is:
http://www.cfas.org/, the new site is http://cfas-new.kronenpj.dyndns.org/.
glad to help where I can :)
Essentially, I'd like the third column flush against the header. I
think it'll work if I can convince Forrest to place that column in its
own <div id="rightbar">. Unfortunately since it's part of the source
file, it's part of <div id="content">. I looked briefly at writing a
new contract but I don't know enough about them to know if that's even a
valid approach.
Have you read the documentation on views?
http://forrest.apache.org/docs_0_80/howto/howto-view-dsl.html
IIUC, all you need to do is put some of the content (like your quicklinks and
news items on the old site) within another <forrest:hook> in the view file
for the front page (most likely it should be named index.fv) and thats it!
Just in case you didn't know, you can specify per file as well as per
directory view configs. So, each page can have a different layout, all pages
in the same directory can have a different layout and so on!
The naming convention is that for a file named foo.xml, Forrest will look for
foo.fv, and then default.fv in the directory containing foo.xml, and then the
project wide default.fv and then finally the default.fv that ships with
views.
HTH,
Diwaker