Ok here’s what’s happened:
* via FTP I deleted the only file in the auth directory. (index.html)
* then I logged into my dbman
* then via FTP I refreshed the directory and saw the file: DavidMeade.9579063044850
* then in the database I clicked: “Delete”
* and then “list all”
* and then checked all but one record
* and then clicked the delete (submit) button.
* I received the following error:
Code:
Oops, there was a problem logging into the system:
invalid/expired user session. Please try logging in again, or contact the system administrator.
* Then via FTP I refreshed the directory and the file DavidMeade….. still existed.
The follwing is a complete listing of my delete_form.
Code:
sub html_delete_form {
# --------------------------------------------------------
# The user has searched the database for deletion and must now
# pick which records to delete from the records returned. This page
# should produce a checkbox with name=ID value=delete for each record.
# We have to do a little work to convert the array @hits that contains
# the search results to a hash for printing.
my ($status, @hits) = &query("mod");
my ($numhits) = ($#hits+1) / ($#db_cols+1);
my ($maxhits); $in{'mh'} ? ($maxhits = $in{'mh'}) : ($maxhits = $db_max_hits);
my (%tmp);
$page_title = "Delete Record(s)";
&html_page_top;
$submit_button = "Delete Checked Record(s)";
$reset_button = "Reset Form";
if ($status ne "ok") { # There was an error searching!
print qq|<P><FONT COLOR="red">Error: $status</FONT>|;
&html_footer;
&html_page_bottom;
}
else {
# < -- Start page text -- >
print qq|
<p>
Check which records you wish to delete and then press "Delete Records":<br>
|;
# < -- End page text -->
if ($db_next_hits) { print "<br><$font>Pages: $db_next_hits</font>"; }
print qq|
<form action="$db_script_url" METHOD="POST">
<input type=hidden name="db" value="$db_setup">
<input type=hidden name="uid" value="$db_uid">
|;
# Go through each hit and convert the array to hash and send to
# html_record for printing. Also add a checkbox with name=key and value=delete.
print qq|
<DIV CLASS="ac">
<TABLE BORDER="1" CELLPADDING="3">
<TR>
<TH COLSPAN="6">David Meade's</TH>
</TR>
<TR>
<TD CLASS="sub1" ALIGN="CENTER">Select</TD>
<TD CLASS="sub1" ALIGN="CENTER">Middle Name</TD>
<TD CLASS="sub1" ALIGN="CENTER">Location</TD>
<TD CLASS="sub1" ALIGN="CENTER">Age</TD>
<TD CLASS="sub1" ALIGN="CENTER">Email</TD>
<TD CLASS="sub1" ALIGN="CENTER">URL</TD>
</TR>
<TR>
|;
for (0 .. $numhits - 1) {
%tmp = &array_to_hash($_, @hits);
print qq|<TD><INPUT TYPE=CHECKBOX NAME="$tmp{$db_key}" VALUE="delete"></TD>|;
&html_record (%tmp);
print qq|</TR>\n|;
}
print qq|
</TABLE>
<INPUT TYPE="SUBMIT" name="delete_records" VALUE="$submit_button">
<INPUT TYPE="RESET" VALUE="$reset_button">
</DIV>
</form>
|;
if ($db_next_hits) { print "<br>Pages: $db_next_hits"; }
&html_footer;
&html_page_bottom;
}
}