Squishdot DTML Organization Zope DTML Butch Landingin butchland@yahoo.com 1 stuff-to-read This article delves into the structure and composition of the DTML methods that make up Squishdot. Hopefully, this will serve as a guide for those of you who wish to modify the look and feel of Squishdot and need to understand the interdependence of the methods and associated folders. %%
The main table consists of three columns, the leftmost column containing leftbox options, the middle column containing the articles themselves, and the rightmost column containing the various squishboxes specified in the rightbox options.
In the case where the TinyTable product is not available and the default leftbox items and right box items are not loaded, each set of options are rendered by hardcoding them into the DTML, instead of being iterated over a table.
The site header (site_header) contains the advertising banner and the topic image url list, as well as several properties such as the title images, the page title and the border background color.
The site footer (site_footer) contains a search form, the quotation, the copyright announcement as well as the list of bottom links. Additional code is also provided so that if in case the TinyTable product is not available and the bottom items table is not loaded, then the bottom links are rendered by hardcoding them into the DTML, instead of iterating over the table.
Each article contains the title, summary, topic subject, the topic image associated with the topic subject as well as a link to the read more page for the given article id.
The read more page consists of the site header, site footer and the main table. The site header and site footer are the same ones used in the main page.
The main table consists of three columns, with the leftmost column similar in content to the leftmost column in the main page, except for some additional hardcoded links discussed above. The right hand column contains a squishbox containing items and URLs related to the article. If a file was attached to to the main article then a squishbox containing it would also be displayed.
The middle column contains the summary and body of the article. In addition, adjoining rows contain the comments and replies to comments. This section probably contains the most complicated set of DTML tags in squishdot and represent an attempt to create a hierarchical display of comments.
In the case that the number of comments exceed the threshold set in the comment spillover property in the Properties page, only the titles, names of the author and posting time are displayed along with a link to the body of the comment is displayed.
The main column contains a form for submitting the article or comment for adding to the database. Depending on what object called it, it either displays an submission form for a main article or a comment. If it's a submission form for a comment, it displays the original article or comment to which you are replying to for convenience. Note: One the things we will be working on for the next feature release (0.3) will be to to add a preview page so that you can see exactly what your article or comment will look like prior to finally committing it to the database permanently and allow you to edit it or back it out of submission completely.
It integrates the contents of Read More page (posting_html) with the Add Posting page. The Preview posting page is displayed when the preview button on the Add Posting page is pressed or if the add button is pressed but an error message is displayed -- instead of transferring back to the add posting page, pressing OK on the error message display will go to the Preview posting page enabling you to see how your posting would look prior to actually submitting it. Otherwise, the structure of the tables on the page are the same as the ones used on the Add Posting and Read More pages.
The other column contains a submission form for searching. It specifies the criteria used for searching.