ssss
05-03-2005, 06:41 AM
I'm new to perl but i've managed to create a perl script that adds values from an html form to a text file, which works fine. The next step is to stop duplicate username's from being created. Is there a way of searching the text file before inserting?
This is how the script is set out:
print txt "-----------------------------------\n";
print txt "$FORM{'Forename'}\n";
print txt "$FORM{'Surname'}\n";
print txt "$FORM{'Email'}\n";
print txt "$FORM{'Login'}\n";
print txt "Password: $Password\n";
So the text file stores data like this:
-----------------------------------
forename
surname
forname.surname@domain.com
forname.surname
Password: 75563844
This is how the script is set out:
print txt "-----------------------------------\n";
print txt "$FORM{'Forename'}\n";
print txt "$FORM{'Surname'}\n";
print txt "$FORM{'Email'}\n";
print txt "$FORM{'Login'}\n";
print txt "Password: $Password\n";
So the text file stores data like this:
-----------------------------------
forename
surname
forname.surname@domain.com
forname.surname
Password: 75563844