#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2000
    Location
    Manchester, UK
    Posts
    47
    Rep Power
    14
    My Perl script creates files named after a form input. So if the user entered infomation and his name was fred, his datafile would be called fred.txt
    But if another person called fred signs up, the file will be overwritten. Can Perl name a script 'filename1.txt' and increment the 1 each time the name is repeated?

    Would appreciate any help.
    Cheers
  2. #2
  3. No Profile Picture
    freebsd
    Guest
    Devshed Newbie (0 - 499 posts)
    Just write everything to one line with a delimiter separating each fields and a newline n at the end of each line. On next try, fred's entry would be on the 2nd line.

IMN logo majestic logo threadwatch logo seochat tools logo