Terms Infusion (Dictionary/Glossary) v1.00 (beta_10052006)
PHP-Fusion: v6.00.3xx
original author: muscapaul
email: muscapaul@gmail.com)
web: www.muscapaul.com
date: 12 May 2006
--------------------------------------------------
Copyright: Released under the terms and conditions
of the GNU General Public License (Version 2)
--------------------------------------------------

FEATURES
--------
* This infusion provides the possibility to build a dictionary or glossary with your own chosen terms.
* The terms can be categorized in categories of your own definition.
* Translations/descriptions can be formatted using BBcode.
* Members can submit terms that are placed in the category 'Submitted' (which is created upon infusion). Admins can publish submitted terms by transferring them to publicly visible categories.
* Visibility access can be set for each separate category (enabling 'premium access' to categories for members, if so desired).
* Individual terms can always be commented on, allowing suggestions for alternative translations.
* Terms can be designated as synonyms with a link to the correct word.
* Ratings system for individual terms optional (general setting by default set to off).
* Maximum number of displayed items on a page can be changed by the visitor (default: 20).
* Visitor can choose to view lists with or without the synonyms.
* Upon infusion a Dictionary/Glossary link is added to the Navigation panel.
* A panel can be added that shows the number of submitted Terms.

CHANGED FILES
-------------
None.

COMMENTS
--------
* The skeleton of this infusion was the Advanced Download DB V2.10 by Giuseppe Nichelini (nick56). Lots of redundant code were removed (uploading files, images, etc.), new code was added and some parts were recoded (for example to set access levels).

INSTALL
-------
1. Copy the contents of the php-files folder to the corresponding folders on your server.

2. Go via Admin Panel -> System Admin to Infusions and install the Terms infusion.

3. Go via Admin Panel -> Infusions to Terms and click the Terms General Settings button. Default language to translate from is the Site Language. Change this if necessary. No language is set to translate to. This should be set now. If so desired, change the setting to allow rating of terms.

4. Go via Admin Panel -> System Admin to Panels and create a new side panel. From the Panel Filename drop-down menu choose 'term_submissions_panel', give it an appropriate panel name (e.g., Term Submissions) and set the appropriate access. Save the panel, go back to Panel Management and enable the panel. Reposition as desired.

UPGRADE
-------
To upgrade from the beta_25042006 to beta_28042006 you need to upload the contents of the php-files folder to the corresponding folders on your server. Next you go to Admin Panel -> Content Admin -> Custom Pages. Put 'Upgrade' in the field 'Page Title' and paste the contents of the file upgrade_2504to2804.txt in the field 'Page Content'. Click on 'Preview Page'. There is no need to save the page. Your upgrade is complete.

To upgrade from Dictionary beta_28042006 to Terms beta_12052006 follow the following procedure:
1. The upgrade script will make changes to the database so make a complete backup of your database via Admin Panel -> System Admin -> Database Backup.
2. If you already have terms in the Dictionary, check if one of the categories has dict_cat_id=1. You can check this by going to Manage Categories and hovering the mouse over each of the category names. If none of the links ends with 'cat_id=1', continue at step 3. If the link in the status bar for any of them ends with 'cat_id=1', then that is one with dict_cat_id=1. All items in this category need to be moved to new category. Create a new category. You can create it exactly as the existing category with dict_cat_id=1 (though it helps if you can easily distinguish between the two) and move the items that are presently in the category with dict_cat_id=1 to the new category. Then delete the category with dict_cat_id=1.
3. Go to Admin Panel -> System Admin -> Database Backup and make a backup of the tables [fusion]_dict, [fusion]_dict_cats and [fusion]_dict_settings.
4. Go to Admin Panel -> Content Admin -> Custom Pages. Put 'Upgrade' in the field 'Page Title' and paste the contents of the file upgrade_2804to1205.txt in the field 'Page Content'. Click on 'Preview Page'. There is no need to save the page.
5. Go to Admin Panel -> System Admin -> Database Backup and make a backup of the tables [fusion]_terms, [fusion]_term_cats and [fusion]_term_settings.
6. Go to Admin Panel -> Content Admin -> Infusions. Defuse the Dictionary infusion.
7. Copy the contents of the php-files folder from the Terms infusion package to the corresponding folders on your server.
8. Go to Admin Panel -> System Admin -> Infusions and install the Terms infusion.
9. Go to Admin Panel -> System Admin -> Database Backup and restore the last backup you made (with the tables [fusion]_terms, [fusion]_term_cats and [fusion]_term_settings).
10. Check if the Terms infusion works and if all categories and term have been ported to the new infusion succesfully. Then delete the folder dictionary from your infusions folder.

CHANGELOG
---------
v1.00
* None (first release)

Bugs encountered and fixed:
* Division by zero error on dictionary.php -> There were two statements giving the number of items per page for page navigation, one of these was set at 0. This was corrected.
* Several page navigation errors on occured on dictionary.php -> The number of items counted was the number of categories + the number of items in the selected category. When the numer of items in the selected category was near the maximum number of items to be displayed on a page, erroneously a extra page would be added that displayed the wrong category and access levels were not taken into account correctly. This was corrected.
* On adding a new category the administrator is sent to Term Management rather than returned to Category Management -> This was changed.
* Table layout on admin pages in some themes corrupt -> Layout incompletely defined. This was corrected.

TO DO
-----
Short term:
* Make the user selection for the display of synonyms and for the number of items per page be carried to the next page when using page navigation. At present these settings fall back to the default Yes and 20 when one goes to another page than page 1.
* Allow the selection of a usergroup to edit terms and categories and to approve terms.

Longer term:
* Add a second set of locale files that can be used if the Dictionary infusion serves as a Glossary rather than a true Dictionary. This set to be selected before infusion!
* Add code tags [glos] [/glos] that will lead visitors immediately to the page with the explained term (when used as Glossary).