Eliot,
The code that I posted above WAS from
sub html_record_long. I just did not include the whole sub because it is quite lengthy.
Below is the code that I am using to switch between databases.
Code:
#
#
# ----------------------
# DBMan
# ----------------------
# Database Administrator
#
# File: format.pl
# Description: This is the file that that sets up a global setting for multiple databases. It
# also contains sub-routines to switch between database files.
#
##########################################################
## HTML Globals ##
##########################################################
# Put any globals you like in here for your html pages.
$html_title = 'AntiqueExchange.net';
# Add your email address. Be sure to leave the \ before the @
$admin_email = "maps1\@erols.com";
# Set your font preferences below
#
$face = 'font face=Verdana, Arial, Helvetica'; # font face for pages
$font = "$face size=2"; # size of normal text
$font_color = "$font color=#003399"; # an alternate color font for html_record
$font_title = "$face size=4"; # size of title text
$error_color = 'font color=red'; # color of error messages
$font_error = "$face size=4 color=red"; # large font for error messages
###############################################################################################
##########################---SUB SWITCH_TO_COMP_DB------#######################################
sub switch_to_user_db{
@db_cols = qw(Userid Company Address1 Address2 City State Zip Phone Fax Email URL);
$db_file_name = $db_script_path . "/user.db";
$db_key_pos = 0;
}
##############################################################################################
#############################----SUB SWITCH_TO_DEFAULT_DB------###############################
sub switch_to_default_db{
@db_cols = qw(Userid ID Category Title Price Quantity Date Desc1 Desc2 Desc3);
$db_file_name = $db_script_path . "/default.db";
}
1
You can find my http://207.96.11.60/jpdeni/html.txt
http://207.96.11.60/jpdeni/default.txt
[This message has been edited by dataKing (edited February 11, 2000).]