|
Latest Version : 0.8.5b
eMail : orvio@orvio.de
Changes :
- Code revision to let Toolbase execute faster
- Added counter
- Add section to path alias support
- User area modified
- Parameters to control the script have changed
What is Toolbase?
Toolbase is a Perl based database system to maintain bigger download-archives without the need to use other systems
like SQL. The appereance can be changed by using a templatefile and a configurationfile.
What do I need to run Toolbase?
At first you need a webserver on that you have permission to run perl scripts. Toolbase needs the CGI module.
If a halfway up-to-date version of perl (Perl 5) is installed you got this module already. Itīs tested on Linux and NT systems and it works fine on them.
Download
Documentation
General
Call the script with the argument ?action=login to alter the database.
If you log in as a normla user you will only see the items assigned to you. If you log in as
admin you will see all items. Items marked with * are not assigned with your account(you may alter
them anyway) and items marked with ! are assigned to an invalid user(or none).
Place everything you wanīt to tell the users of your archive in the note.txt file. It will be displayed
when the archive.pl script is called without arguments.
You can change the template.html file to fit your needs, but make sure that that
the tags used by toolbase are included(see the template.html file that comes with Toolbase to
see where to place them).
The archive.usr file
Here the Toolabse-users are specified. The syntax follows these rules:
set NAME PASSWORD
The archive.cfg file
With this file the archive.pl script is configured. Tze Syntax follows these rules:
set KEY VALUE
- TOOLBASE_DATA_DIR This variable points to the directory where Toolbase will store its database.
The path will be interpreted as relative to the path were archive.pl lies.
- ADMIN Here you can specify one of the users named in archive.usr to be the
administrator of the archive. Since this user gains some special rights
you might want to let this point to a non-existing user or leave it empty
to avoid giving special rights to any of your users.
- NOTE_FILE This names a file to be displayed when the script is called without the
'arg'-parameter specified. The place must be named relative to the place
where archive.pl lies. The content of this file will be inserted as it is, so
you can use HTML-code as you like. To turn this off use the SHOW_NOTE_FILE key.
- SHOW_NOTE_FILE if set to true the file in NOTE_FILE will be displayed when the script is called withous arguments
- BACKGROUND_COLOR1 This sets the background color for the tablecells in which the pictures for
the items are displayed. Set to 'NONE' if you don't want to use any.
- BACKGROUND_COLOR2 This sets the background color for all normal tablecells. Set to 'NONE' if
you don't want to use any.
- BACKGROUND_COLOR2 This sets the background color for table headers. Set to 'NONE' if you don't
want to use any.
- TABLE_DEFAULT_COLOR This sets the default color for the table in which Toolbase will display its
information. Set to 'NONE' if you don't want to use any.
- SHOW_SECTABLE
SHOW_SECMENU Toolbase is able to display a list of the sections so that one can jump from
one to another easily. This list might be displayed is a table or as a
pop-up menu. Choose the one of your favour and enable it by setting
the corresponding key to 'true' or disable it with 'false'. You may have both
of them enable or disabled at the same time.
- TEMPLATE_FILE This key points to the the template file that Toolbase should use for
displaying its output. If you let this point to a file that cannot be
opened or that does not fit the requirements of Toolbase its output will
either be empty(if the file cannot be opened) or Toolbase will just display
the templatefile without adding anything.
- SHOW_PICS If you want to let Toolbase to display icons for the items(you have to have
ourself) set this to 'true'. If not set it to 'false'.
- PIC_WIDTH
PIC_HEIGHT This two keys set the size of the icons. All icons will have the size
you have specified here. If you have set SHOW_PICS to 'false' forget
thsi two keys.
- SHOW_HOMEPAGE You may enter a URL pointing to the homepage for each item that
will be displayed whenever . If don't want this to be displayed never set it
to 'false'. If you want a URL to the item's homepage to be displayed then and
there set it to 'true'. If you don't enter a URL for an item Toolbase will act
as if you said 'false' here.
- ALLOW_DIRECT_DOWNLOAD This affects the download links in the same manner as the SHOW_HOMEPAGE key
affects the homepage links.
- SECTIONS Here you enter the sections for your archive. Sections have to be specified
as a comma-separated list. Spaces and underscores are not allowed and
section names containing them will be ignored.
- SECTION_TO_PATH_ALIAS You may connect a section name to a path. This has to be done as a list
of key-value pairs, separated by commas.(Secname_/path,Sec2_/path/path,....)
You may only use pathnames on top of your document root. e.g: If your document
root is set to '/home/www' and you set a pathalias for section 'Test' to
path '/files' ('Test_/files') then Toolbase will display the content of
'/home/www/files' whenever it gets a call to display section 'Test'.
- SUB_SECTIONS_ You may define various sub-sections for any of your sections defined with
SECTIONS. Create a key for each section that should contain sub-sections :
SUB_SECTION_secname
Replace 'secname' with the name of the appropriate section.
Subsections are named the same way as the main-sections are(The
comma-sparated list, you remember ...). Don't forget that spaces and
underscores are still not allowed. If you create sub-sections for
sections that have a path alias the sub-sections will be ignored.
- ARCHIVE_TITLE This sets the name of your archive. It will be used to create the title
of the generated HTML-files.
- ALLOW_SEARCH If you want to allow your archive to be searched from the mainpage
say 'true'. if not say 'false'.
- ALLOW_SEARCH If you want to allow your archive to be searched from every page set this
to 'true'. If not set it to 'false'.
- SHOW_EDIT If you want a little link next to every item taking you to screen that
allows you to edit that item set this to 'true' if not set it to 'false'.
- USE_FLOCK If your server does not support file locking set this to 'false'. Most
servers should support this but, so that you don't have ot worry about it.
- USE_COUNTER Toolbase is able to count how often a link has been called and to display
this information together with the information available for an item.
If you want Toolbase to do so. Say 'true' if not say 'false'.
The archive.pl script
Change the line
$BASE_DIR = "./";
To the path to your cgi-bin. In most servers you can use relative pathnames. If th script is in your cgi-bin directory you can set BASE_DIR to ./
License
Copyright (c) 1999 - 2003 Martin Mueller
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
- Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
- All advertising materials mentioning features or use of this software
must display the following acknowledgement:
This product includes software developed by Martin Mueller
- The name of the author may not be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
If you want to send a bugreport or if you have ideas
to improve Toolbase e-mail me!
|