[Moin-user] Newbie: attaching forms / metadata with pages?
Nir Soffer
nirs at actcom.net.il
Fri Oct 21 12:41:30 EDT 2005
On 21 Oct, 2005, at 20:56, Ramon Felciano wrote:
> I'd like to try use a wiki -- preferrably MoinMoin -- to track a set of
> evolving requirements. However, we need a way of associating some forms
> data with each page (e.g. rankings for difficulty, priority, expense,
> etc). Is there a straighforward way to set up a page template that
> includes such fields so that you could write a plug in that would
> create
> summary reports (e.g. a list of all requirements, ranked by priority)?
> I've looked through the 2 wiki pages that mention forms, but neither
> really indicates if and how this could be implemented today.
There is no builtin way to do this.
The simplest solution is to use definition lists for the meta data:
key:: value
And then use a FullSearch and regular expressions to look for the data.
But this will give you very primitive interface. For better system, you
will have to write your own search and display code.
Another way to add meta data to a page is with #pragma:
## This is the top of the page
#pragma key value
This is page text...
Pragmas are displayed on the page, but you can add some code to display
them in your theme.
Another way to add meta data to a page is with section parser:
{{{
#!meta
key:: value
}}}
Now it will be easier to search for your data, or to change the way it
is presented, or to update a cache or an index when you render the
page.
See http://moinmoin.wikiwikiweb.de/SectionParser
In all cases, you will have to write the code that search the meta data
and display the results. If you got only 200-300 pages to search, a
simple text search will be just fine.
If you think about few thousands pages, you need some caching or maybe
use indexing search engine like Lupy, which is bundled with release
1.3.5. With little modification, you can add the page meta data to the
lupy index, like we already do with page links.
Best Regards,
Nir Soffer
More information about the Moin-user
mailing list