The version I have is the exact same one, and it still prints nothing for the password. The email is sent and everything, but the password field appears as :
Password:
???
Here is what I have in Links.def:
=========================================================================================
# Database Definition: LINKS
# --------------------------------------------------------
# Definition of your database file.
%db_def = (
ID => [0, 'numer', 5, 8, 1, '', ''],
Title => [1, 'alpha', 40, 75, 1, '', ''],
URL => [2, 'alpha', 40, 75, 1, 'http://', '^http|news|mailto|ftp'],
Date => [3, 'date', 15, 15, 1, \&get_date, ''],
Category => [4, 'alpha', 0, 150, 1, '', ''],
Description => [5, 'alpha', '40x3', 500, 0, '', ''],
'Contact Name' => [6, 'alpha', 40, 75, 1, '', ''],
'Contact Email' => [7, 'alpha', 40, 75, 1, '', '.+@.+\..+'],
Hits => [8, 'numer', 10, 10, 1, '0', '\d+'],
isNew => [9, 'alpha', 0, 5, 0, 'No', ''],
isPopular => [10, 'alpha', 0, 5, 0, 'No', ''],
Rating => [11, 'numer', 10, 10, 1, 0, '^[\d\.]+$'],
Votes => [12, 'numer', 10, 10, 1, 0, '^\d+$'],
ReceiveMail => [13, 'alpha', 10, 10, 1, 'Yes', 'No|Yes'],
Password => [20, 'alpha', 10, 10, 1, '', '']
);
# Database file to use -- defined in links.cfg.
$db_file_name = $db_links_name;
# Counter file to use -- defined in links.cfg.
$db_id_file_name = $db_links_id_file_name;
# The column name for the database key.
$db_key = 'ID';
# Database delimeter.
$db_delim = '|';
# Title used in admin output.
$html_title = 'Links Database';
$html_object = 'Link';
# Field Number of some important fields. The number is from %db_def above
# where the first field equals 0.
$db_category = 4; $db_modified = 3; $db_url = 2;
$db_hits = 8; $db_isnew = 9; $db_ispop = 10;
$db_contact_name = 6; $db_contact_email = 7; $db_title = 1;
$db_votes = 12; $db_rating = 11; $db_mail = 13;
$db_password = 20;
=========================================================================================
Here is what I have in Password.cgi:
=========================================================================================
#***********************************************************
# Use the info in links.def to find the values you want.
# These are the default values. If you have added fields, then
# make sure that you define it by $db_newfield = 14; and then
# to get the value, you can call it by $data[$db_newfield]
#
# $db_category = 4; $db_modified = 3; $db_url = 2;
# $db_hits = 8; $db_isnew = 9; $db_ispop = 10;
# $db_contact_name = 6; $db_contact_email = 7; $db_title = 1;
# $db_votes = 12; $db_rating = 11; $db_mail = 13; $db_password = 20;
#**********************************************************
open (MAIL_RECIP, "|$MAIL_PROGRAM");
print MAIL_RECIP "To: $email\n";
print MAIL_RECIP "From: $admin\n";
print MAIL_RECIP "Subject: Password Request\n";
print MAIL_RECIP "You have requested your login info to -:hibrid:- for $email.\n";
print MAIL_RECIP "Resource ID: $data[0]\n";
print MAIL_RECIP "URL : $data[$db_url]\n";
print MAIL_RECIP "Email : $data[$db_contact_email]\n";
print MAIL_RECIP "Password : $data[$db_password]\n";
close(MAIL_RECIP);
} # end of foreach
=========================================================================================
Anyone see any mistake?
Thanks a lot.
Aymeric.
Password:
???
Here is what I have in Links.def:
=========================================================================================
# Database Definition: LINKS
# --------------------------------------------------------
# Definition of your database file.
%db_def = (
ID => [0, 'numer', 5, 8, 1, '', ''],
Title => [1, 'alpha', 40, 75, 1, '', ''],
URL => [2, 'alpha', 40, 75, 1, 'http://', '^http|news|mailto|ftp'],
Date => [3, 'date', 15, 15, 1, \&get_date, ''],
Category => [4, 'alpha', 0, 150, 1, '', ''],
Description => [5, 'alpha', '40x3', 500, 0, '', ''],
'Contact Name' => [6, 'alpha', 40, 75, 1, '', ''],
'Contact Email' => [7, 'alpha', 40, 75, 1, '', '.+@.+\..+'],
Hits => [8, 'numer', 10, 10, 1, '0', '\d+'],
isNew => [9, 'alpha', 0, 5, 0, 'No', ''],
isPopular => [10, 'alpha', 0, 5, 0, 'No', ''],
Rating => [11, 'numer', 10, 10, 1, 0, '^[\d\.]+$'],
Votes => [12, 'numer', 10, 10, 1, 0, '^\d+$'],
ReceiveMail => [13, 'alpha', 10, 10, 1, 'Yes', 'No|Yes'],
Password => [20, 'alpha', 10, 10, 1, '', '']
);
# Database file to use -- defined in links.cfg.
$db_file_name = $db_links_name;
# Counter file to use -- defined in links.cfg.
$db_id_file_name = $db_links_id_file_name;
# The column name for the database key.
$db_key = 'ID';
# Database delimeter.
$db_delim = '|';
# Title used in admin output.
$html_title = 'Links Database';
$html_object = 'Link';
# Field Number of some important fields. The number is from %db_def above
# where the first field equals 0.
$db_category = 4; $db_modified = 3; $db_url = 2;
$db_hits = 8; $db_isnew = 9; $db_ispop = 10;
$db_contact_name = 6; $db_contact_email = 7; $db_title = 1;
$db_votes = 12; $db_rating = 11; $db_mail = 13;
$db_password = 20;
=========================================================================================
Here is what I have in Password.cgi:
=========================================================================================
#***********************************************************
# Use the info in links.def to find the values you want.
# These are the default values. If you have added fields, then
# make sure that you define it by $db_newfield = 14; and then
# to get the value, you can call it by $data[$db_newfield]
#
# $db_category = 4; $db_modified = 3; $db_url = 2;
# $db_hits = 8; $db_isnew = 9; $db_ispop = 10;
# $db_contact_name = 6; $db_contact_email = 7; $db_title = 1;
# $db_votes = 12; $db_rating = 11; $db_mail = 13; $db_password = 20;
#**********************************************************
open (MAIL_RECIP, "|$MAIL_PROGRAM");
print MAIL_RECIP "To: $email\n";
print MAIL_RECIP "From: $admin\n";
print MAIL_RECIP "Subject: Password Request\n";
print MAIL_RECIP "You have requested your login info to -:hibrid:- for $email.\n";
print MAIL_RECIP "Resource ID: $data[0]\n";
print MAIL_RECIP "URL : $data[$db_url]\n";
print MAIL_RECIP "Email : $data[$db_contact_email]\n";
print MAIL_RECIP "Password : $data[$db_password]\n";
close(MAIL_RECIP);
} # end of foreach
=========================================================================================
Anyone see any mistake?
Thanks a lot.
Aymeric.