Working With the Templates
The templates live inside of the Templates folder inside the WebDB datafolder. this way you can easily set up many instances of Tabs on the Web with totally different templates.
It's not necessary to look through this page at all. You can learn everything you need to by customising the demo templates that come with the app. All the necessary techniques are shown there. Feel free to change ANY of the surrounding HTML code to customise the look and layout of your page as long as you use the special TOTW tags in a similar manner to what is shown.
- Entry Page Template
This template is what is sent when someone first hits the acgi program. It can be completely customized for your application. It provides 3 special tags that can be used to enter the database to search, browse or Administer.
<searchlink>, used like <a href="<searchlink>">Search the database</a>
These tags are valid in every page. If you wish to have a link bar at the bottom of the screen you may include thise links in every page, as in the example templates. These are the ONLY tags that are valid in every page.
<browselink>, used like <a href="<browselink>">Browse the database</a>
<admin link>, used like <a href="<admin link>">Signon to Admin Functions</a>
- Browse By Page Template
If someone clicks on the Browse The Database link they will be taken to this page. It contains a form that will have radio buttons for the indexed fields you wish to search. You do not need to have a search button for every field you have indexed. The following new tags are valid in this page. See the demo template for more info.
<browse form action>
This should be in the action link of the form on the page
<index Field Name>
You create one of these for each of the fields you want to search. it will be replaced by a radio button form element.
- Search Page Template
This page is almost identical to the browse page template with the addition of the search text field.
<index Field Name>
You create one of these for each of the fields you want to search.
<lastsearch>
will be replace with the last search that the person did. Not necessary but a nice feature. See the demo template for more info on using this in the form.
you must also include an input field for the searchtext to be entered into like:
<input type=text name=searchstring value="<lastsearch>">
- Browse Page Template
After searching, or while browsing, TOTW will allow you to walk through a list page by page of the hits and select which one you would like to like to view the detail page of. This is by far the most complicated page to setup.
You setup an ordinary HTML table and then define a row for the table which TOTW will repeat for each line. See the demo template for more detail on how to do this. The example also defines an odd and even row color for the table to make reading it easier.
<OddRowColor Color>
and
<EvenRowColor Color>
The repeating line should be between the
<line start> and <line end>
tags and look something like:
<line start>
<tr>
<td bgcolor=<bgcolor>> <a href="<detail link>"> <field first name> <field last name></a> </td>
<td bgcolor=<bgcolor>> <field address> </td>
<td bgcolor=<bgcolor>> <field extension> </td>
</tr>
<line end>
To insert the link to the detail page use the
<detail link>
and to display the data from a field use the<field Field Name>
FormatThis is as far as I got for the first beta release. Check out the demo files and you should be able to understand whats going on. More documentation will be included in future beta versions!