Static Pages | ||
---|---|---|
Prev | Chapter 2. Developer's guide |
This is the requirements document for the Static Pages package.
The Static Pages package searches the file system for static pages and loads them into the database. Because all pages are stored in the database, their contents are available to site-wide-search and other packages. The system also accepts and displays user-contributed comments on static pages. Site administrators may easily manage these functions (to disallow comments on certain pages, for example) via the admin pages.
The Static Pages package stores every static page on the site in the content repository so that they will be available to site-wide-search and other packages. When a commentable static page is requested, the general-comments package is used to attach to it a list of existing comments and an "add a comment" link. In this way, the problems of storing and searching content and managing comments are passed on to other packages.
an administrator wants to know which static pages contain the word "pomegranate" (without using grep)
an administrator wants to allow users to make comments on some pages but not on others
a user visiting the ca-pomegranates.html page wants to register his opinion about coastal vs. foothill pomegranates.
The administrator's UI will include a command to synchronize the database contents with the static files in the filesystem.
For any given static page, the administrator will be able to specify the following:
Whether comments may be made on the page
Whether comments are shown on the page
Whether the page is included in a site-wide search [deferred]
An administrator will be able to exclude from the site-wide index any static pages whose URL or title match a pattern.
An administrator will be able to the commentability status of any static pages whose URL or title match a pattern.
An administrator will be able to view a report summarizing the number, age, etc. of comments made on each static page. [This requires support from general-comments. A feature request has been put in.]
When a user visits a static page on which comments are permitted, the existing comments will be displayed (if the administrator has designated that they should be) along with a link to add a new comment.
The contents of static pages will be made available to the site-wide-search package.
The ACS 3.x version of Static Pages would log each hit to a static page so that it could produce a report showing who hit each page and which pages a particular user visited. These functions belong in a "clickstream" package that tracks statistics for all pages, not just static ones.
ACS 3.x Static Pages also included a spider to visit each static page and check for bad links. Again, this feature is not specific to static pages, and is better addressed with a more general tool.
Section 2.2.5.6: implement by using rp_register_extension_handler to register a proc for *.html files. The registered proc will check if the page is commentable, and if so make the necessary calls to general-comments. The "is this page commentable?" query will be cached with util_memoize.
Section 2.2.5.7: site-wide-search can search anything in the content repository, so that's where the pages should be stored.
Section 2.2.5.3: implement using CR folders to allow admins to exclude entire directories.
Designate commentability using the general_comments_create privilege defined by the general-comments package.
Document Revision # | Action Taken, Notes | When? | By Whom? |
---|---|---|---|
0.4 | Cleaned up for release. | 2001/03/05 | Brandoch Calef |
0.3 | Some features really belong in general-comments, and have been marked as such. | 2001/02/27 | Brandoch Calef |
0.2 | Incorporation of suggestions from mbryzek. | 2001/01/23 | Brandoch Calef |
0.1 | Creation | 2001/01/19 | Brandoch Calef |
$Id: static-pages-requirements.html,v 1.2 2018/07/11 21:57:26 hectorr Exp $