Smart Archive Setup Instructions
Smart Archive Setup Instructions
Folder:
File:
Description:
/
add.cgi
Add files and signup for new accounts.
/
admin.cgi
Control the archive from here.
/
smartarchive.cgi
Displays and searches the files.
/
download.cgi
Download files and performs related tasks.
/
cron_reset.cgi
Reset the file download stats.
/
cron_update.cgi
Create/update the archive html pages.
/
java_info.cgi
Display lots of info about archive using javascript tag.
/
vars.cgi
Holds variables you need to customize.
/html/
add_header.html
Header HTML for add.cgi pages (see above).
/html/
add_footer,html
Footer HTML for add.cgi pages (see above).
/html/
archive_header.html
Header HTML for all archive pages.
/html/
archive_footer.html
Footer HTML for all archive pages.
/html/
download.html
HTML for file download info page.
/data/
files.data
Stores file info.
/data/
report.data
Stores dead link reports on files.
/data/
submissions.data
Stores files awaiting approval.
/data/
members.data
Stores member account info.
How to Install:
Set the path to perl at the top of each CGI file (except vars.cgi). Default is #!/usr/bin/perl
Open vars.cgi and follow the instructions inside to customize the
script.
Edit all the files in the "html" folder with the HTML you want for your
archive. Help with download.html further down this page (go there).
Create a folder in your cgi-bin, something like "smartarchive".
Create the sub-folders "html" ("smartarchive/html") and
"data" ("smartarchive/data"). Depending on your server, you might need
to change the permissions of these directories to CHMOD 777.
Upload all files in ASCii mode. The CGI files go in the main folder
("smartarchive"), the HTML files go in the "html" sub-directory
("smartarchive/html"), and the data files go in the "data"
sub-directory ("smartarchive/data").
Change the file permissions of all CGI files to CHMOD 755, and the permissions of the
data files (in "smartarchive/data") to CHMOD 777.
You're done setting it up!
How to use:
Unless you make your own customized forms, send people to add.cgi to
add files to the archive, and smartarchive.cgi to search the archive.
If you can use Cron on your server (to run programs automatically at specific times),
you can have it run cron_reset.cgi whenever you want the download stats
reset. Run cron_update.cgi to update the archive HTML pages (You only
need to do this if you are displaying the "number of downloads" on the archive).
The CGI will automatically create HTML pages of your archive everytime a new file is
added, in the directory you specified in vars.cgi. The files will be: archive.html
for a listing of all files, archive_a.html to archive_z.html for each
letter, and archive_other.html for any remaining listings (numbers and special
characters).
What does "java_info.cgi" do?
This CGI is used to provide stats about your archive using Javascript tags, and you can
put them anywhere on any page you want. Each function you can use is described:
Display the amount of credits a user has in his account (if your archive has a ratio
set).
The output is just a number.
HTML to use: <script src="http://yourdomain.com/java_info.cgi?credits=show"></script>
Display the total number of files currently in your archive.
The output is a number.
HTML to use: <script src="http://yourdomain.com/java_info.cgi?total=show"></script>
Display the most downloaded files from your archive (Replace X with any number you
want).
Example output (first line): 1. The Offspring - Original Prankster
(321)
HTML to use: <script src="http://yourdomain.com/java_info.cgi?top=X"></script>
Display the most downloaded files from a specific category (Replace X with any number
you want; Replace CATEGORY with the exact name of the category).
Example output (first line): 1. The Offspring - Original Prankster
(321)
HTML to use: <script src="http://yourdomain.com/java_info.cgi?top=X&cat=CATEGORY"></script>
Display the newest files (Replace X with any number you want).
Example output (first line): 1. The Offspring - Original Prankster
(2/3/01 22:01)
HTML to use: <script src="http://yourdomain.com/java_info.cgi?new=X"></script>
Display the newest files in a specific category only (Replace X with any number you
want; Replace CATEGORY with the exact name of the category).
Example output (first line): 1. The Offspring - Original Prankster
(2/3/01 22:01)
HTML to use: <script src="http://yourdomain.com/java_info.cgi?new=X&cat=CATEGORY"></script>
Display the user's download list (saved for later download).
Example output (first line): The Offspring - Original Prankster
HTML to use: <script src="http://yourdomain.com/java_info.cgi?dlist=show"></script>
Display the top contributors (people who added files) to your archive (Replace X with
any number you want).
Example output (first line): 1. Smart CGIs (43)
HTML to use: <script src="http://yourdomain.com/java_info.cgi?tophelp=X"></script>
Download Page Tags
Your download page has a lot of content that is unique to each file. There are tags you
can place inside your download.html page that will later be replaced by a
value. The tags are all square brackets with a keyword inside, the following table
explains each:
Tag to use:
Description of tag:
[thumbnail]
If you have thumbnails in your archive this tag will be replaced by the
thumbnail image associated with the file.
[filename]
The real name of the file (example: my-head.gif)
[category]
The category the file is in.
[size]
The size of the file (only works if the file is uploaded).
[date]
Date the file was add to the archive.
[provider]
Name of the person (or site) that added the file, with link to their web
site.
[download_link]
This is the link people follow to actually download the file.
[download_number]
The number of times the file was downloaded.
[report]
The URL for people to report that the file is not working (dead link).
[entryX_name]
(X is a value from 1 to 6)
The title of the field describing the file (you have up to 6 of these). Example:
Artist
[entryX_value]
(X is a value from 1 to 6)
The value for one of these fields. Example: The Beatles
If you have any questions you can e-mail webmaster@smartcgis.com
Wyszukiwarka
Podobne podstrony:
setup instructions (2)setup instructions (3)setup instructions (4)setup instructions (11)setup instructions (12)setup instructions (6)setup instructions (8)setup instructions (10)SWS Instructor Setup GuideSAV8 Instructor Setup Guideinstrukcja prezentacja2instrukcja bhp przy obsludze euro grillaDS1000PL InstrukcjaBlaupunkt CR5WH Alarm Clock Radio instrukcja EN i PLInstrukcja do cwiczenia 4 Pomiary oscyloskopoweInstrukcja F (2010)więcej podobnych podstron