Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

A question for a master !

Status
Not open for further replies.

PasPy

Programmer
May 16, 2002
11
CA
#ok, first I'll explain you the main idea. When a user #click on a button delete (p.s.: they have many button #delete with each a number ( or ) #and he was in the user page, so the user is log with a #username and password, and each user have variable in a #files : $username, $password, $first, $last, $address ... #$country, @did) ok i continue, so when the user click on #the delete button, I want to the scripts add the param of #delete in the table @did ! I wish you will understand what #i wanted mean.
#
#1 - my first problem is located in the HTML part of the #CGI...
#
#- I know how to send the " to the sub &delete, but i'm not able to send the user data to the sub delete.

2 - my second trouble is in the sub delete, the scripts erase all my data files when i try modify an user data ...

I try this way but i think something is wrong...

sub delete {

my $delete = shift;
open(FILE, "$datadir/members.iddb");
@data = <FILE>;
close(FILE);
foreach $line (@data) {
($login, $passwd2, $first, $last, $address, $city, $state, $other, $zip, $country, $payment, $email, $total, @did) = split(/\|/, $line);

if ($FORM{'login_6'} eq &quot;$username&quot;) {
$message = &quot;bravo&quot;;
&main;
}
else {
$message = $FORM{'login'};
&login;
}
}
}



very thanks, everyone is welcome

- Paspy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top