A document has been updated:
http://cocoon.zones.apache.org/daisy/cocooninaction/677.html
Document ID: 677
Branch: main
Language: default
Name: The first pages (unchanged)
Document Type: Simple Document (unchanged)
Updated on: 8/19/05 9:31:59 AM
Updated by: Helma van der Linden
A new version has been created, state: draft
Parts
=====
Content
-------
This part has been updated.
Mime type: text/xml (unchanged)
File name: (unchanged)
Size: 12629 bytes (previous version: 9099 bytes)
Content diff:
(7 equal lines skipped)
<p>HealthyCocoon is a hip restaurant located in the centre of Maastricht,
The
Netherlands. Maastricht is practically on the Belgian border and only some
30 km
--- from the German border. We intend to spoil our international clientele by
--- serving them fresh, healthy and nutritional food served in eye-pleasing and
--- tongue-caressing dishes. Not only do we have ample seating inside, but we
also
--- have outside seating for those nice days in spring, summer and autumn.<br/>
--- If you are in a rush, you will find that our dishes are also great for
takeaway.
--- </p>
+++ from the German border, which explains our international clientele.</p>
+++ <p>We intend to spoil our customers by serving them fresh, healthy and
+++ nutritional food served in eye-pleasing and tongue-caressing dishes. Not
only do
+++ we have ample seating inside, but we also have tables and comfortable
chairs set
+++ up outside for those nice days in spring, summer and autumn.</p>
+++
+++ <p>If you are in a rush, you will find that our dishes are also great for
+++ takeaway.</p>
+++
<h3>Address</h3>
<p>HealthyCocoon is located at<br/>
(119 equal lines skipped)
<p>We want the final output to be valid XHTML 1.0 Transitional. Layout is
done
through CSS in separate CSS files, inline styles are only used for
occasional
--- exceptions. All CSS used should be valid as well.</p>
+++ exceptions. All CSS used should be valid as well. And of course it should
all be
+++ UTF-8.</p>
<h3>Directory structure vs URL structure</h3>
(37 equal lines skipped)
during the installation of Cocoon) remains untouched and provides a default
setup for most definitions and URLs.</p>
+++ <h3>Create the home page</h3>
+++
+++ <p>The home page will contain the information about HealthyCocoon. It will
be
+++ the first page to be shown when the domainname is entered and where all
+++ non-existing pages will be directed to.<br/>
+++ Create a new XML file in <em>src/cocoon/webapp/healthycocoon/content</em>
and
+++ name it <em>home.xml</em>. Copy or type the page template, explained above
and
+++ set the <tt>title </tt>and <tt>banner </tt>to 'HealthyCocoon welcomes you'.
Copy
+++ or type the text about HealthyCocoon between the <tt>text </tt>tags. Save
the
+++ file.<br/>
+++ It looks like this:</p>
+++
+++ <pre><page>
+++ <header>
+++ <title>HealthyCocoon Welcomes You</title>
+++ </header>
+++ <content>
+++ <banner>HealthyCocoon Welcomes You</banner>
+++ <text>
+++ <p>
+++ HealthyCocoon is a hip restaurant located in the centre of
Maastricht, The
+++ Netherlands. Maastricht is practically on the Belgian border and
only some 30 km
+++ from the German border, which explains our international clientele.
+++ </p>
+++ <p>
+++ We intend to spoil our customers by serving them fresh, healthy
and nutritional
+++ food served in eye-pleasing and tongue-caressing dishes. Not only
do we have ample
+++ seating inside, but we also have tables and comfortable chairs set
up outside for
+++ those nice days in spring, summer and autumn.
+++ </p>
+++ <p>If you are in a rush, you will find that our dishes are also
great for takeaway.</p>
+++ </text>
+++ </content>
+++ </page></pre>
+++
+++ <h3>Create the contact page</h3>
+++
+++ <p>Repeat the steps above to create <em>contact.xml</em> which contains the
+++ addres of HealthyCocoon. Choose an appropriate title and banner. It looks
like
+++ this:</p>
+++
+++ <pre><page>
+++ <header>
+++ <title>HealthyCocoon - Contact</title>
+++ </header>
+++ <content>
+++ <banner>Where to find us</banner>
+++ <text>
+++ <p>
+++ HealthyCocoon is located at:
+++ </p>
+++ <p>
+++ Webappstreet 25<br/>
+++ 1234 AB Maastricht<br/>
+++ The Netherlands<br/>
+++ </p>
+++ <p>
+++ You can reach us:<br/>
+++ By phone: +31 43 1234567<br/>
+++ By fax: +31 43 1234568<br/>
+++ By email: [EMAIL PROTECTED]<br/>
+++ </p>
+++ </text>
+++ </content>
+++ </page></pre>
+++
+++ <p class="note">Since these files are XML, you are required to write valid
XML.
+++ This means that using HTML tags also requires you to conform to valid XML,
hence
+++ the <tt><br/></tt> and the closing <em></p></em>.</p>
+++
+++ <h3>Putting it to screen</h3>
+++
+++ <p>Now that you have written the content to start with, it is time to focus
on
+++ how to get it to display on screen. For that we need two things:</p>
+++
+++ <ul>
+++ <li>Something, an XSLT stylesheet, that transforms your pages into
XHTML.</li>
+++ <li>Something, a sitemap, that does the directory-to-URL mapping as
discussed
+++ before.</li>
+++ </ul>
+++
+++ <h3>ToXHTML.xslt</h3>
+++
+++ <p>The XSLT stylesheet that transforms the internal markup to XHTML is
+++ conveniently named <em>ToXHTML.xslt</em>. Create an XSL document in
+++ <em>src/cocoon/webapp/healthycocoon/system/xsl</em>. For now we will create
the
+++ simplest stylesheet possible. Enhancements will be added later.<br/>
+++ Create the stylesheet yourself and check if it matches the one below or
simply
+++ copy and paste.</p>
+++
<p>[TODO:<br/>
--- - create home page<br/>
--- - create contact page<br/>
- create xsl files that transform the xml<br/>
- explain about pipelines (enough to understand why there are different xsl
files)<br/>
(7 equal lines skipped)
Fields
======
no changes
Links
=====
no changes
Custom Fields
=============
no changes
Collections
===========
no changes