Password Reminder And Password Change .htaccess - I need a script to change password

free web hosting
Free Web Hosting > Computers & Tech > Programming > Scripting > Perl & CGI

Password Reminder And Password Change .htaccess - I need a script to change password

potnuru
Hi,

I use .htaccess to protect the members area of my site. I use a script called register.pl (search hotscripts and you'll see it) This script takes the username and password provided by the user and then enters the username and the encrypted password into the password file.

What I want to do is, along with the username and password being taken, I want to also take the email address and when the user forgets his/her password all he has to do is type in the email, and the password will be sent.

Thanks in advance, smile.gif
-!DraXxuS!-

Reply

KnightEagle
Found this site on the web. I use one very similar too it think you find it is what you need. http://www.custom-cgi.com/free/cookie_login/ I just started to experiment with it so I can tell you much about it.

Reply

julian2701
Difficult to solve your problem, I think!

Perhaps it's easier if you work with mySQL, the name and password are put in the password-file and in the same script, the name, passwort and entered e-mail are saved in your database!

If anyone lost his password, you can easier use your database to (re)send the password than the htacces-password-file!!

Aditionally, i don't think that youre able to put anything else except the name und encryptet password in htaccess-pwd-file!!

Correct me, if I should be wrong... rolleyes.gif

__________________

Sorry for my probably bad english, but I'm from germany tongue.gif

Reply

ruben
Hello there,

I think it should be possible. You are trying to make up some connection between names and email addresses, right? Well, you can do this by corresponding line: for example
CODE

line 7:htpasswd -bc .htusers Toni one
line 8:htpasswd -bc .htusers Luigi two
line 9:htpasswd -bc .htusers Bernardo three
lline 10:htpasswd -bc .htusers Hernandez four

So if you just read in the .htusers file into an array like the PHP function "file()" You got them grouped by lines. So Mr. Luigi would be Nr. 8. If you now have a database with the emails in it or a textfile (would not recommend that), than you can just give the corresponding line numbers to the email address. So, if Mr. Luigi now tries to get his password send, you take his line number and email address from the database, open the .htusers file with file().. Wait it's easier in code
CODE
$userfile= file(".htusers");
$theline = explode(" ",$userfile[$x=8]); // there are always three spaces (" ") in a line
$user = $theline[2]; // the user name
$password = $theline[3]; // the users password
// email address you got from database. now you can send an email with this data, hope you know how that works. php.net/mail

Should do the job, but you will have to change it for your personal circumstances! Good luck!

regards,
Ruben

Oops, I assumed PHP! Sorry for the double post. I do not know perl at all, but I hope the Idea is clear! Sorry for the double post, may be a mod could edit? Thanks!
Ruben

 

 

 


Reply

jipman
Notice from jipman:

Topic started at 23 may, and still no reply from the topic starter. I think it's justified to close this one down.

Reply


Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

(Maximum characters: 10,000)
You have characters left.

Recent Queries:-
  1. change password php - 24.15 hr back. (1)
  2. how to change htaccess password - 43.88 hr back. (1)
  3. how to make passwords for .htusers - 51.47 hr back. (1)
  4. php password reminder - 53.37 hr back. (1)
  5. htaccess with changing password - 69.84 hr back. (1)
  6. .htaccess wrong password - 69.89 hr back. (1)
  7. .htaccess set password - 18.05 hr back. (2)
  8. website code for user password reminder - 84.08 hr back. (1)
  9. email password change "cgi script" - 95.19 hr back. (1)
  10. php pasword reminder - 99.27 hr back. (1)
  11. password reminder mysql php - 120.60 hr back. (1)
  12. change password in htaccess - 121.81 hr back. (1)
  13. htaccess password change - 124.04 hr back. (1)
  14. how edit htaccess send email from - 166.95 hr back. (1)
Similar Topics

Keywords : password, reminder, password, change, htaccess, script, change, password

  1. Need To Install Script - $10
    (5)
  2. Simple Perl Script...
    (1)
    I want to know the perl path to include at the beginning of the file....so that my perl scripts will
    run properly... Or is it ok to make a cgi-bin directory and put my perl scripts in it? Any reply is
    appreciated. cpn....
  3. Share Your CGI Scripts Here
    (1)
    If You Looking CGI Script or you want share information about it please comment here /cool.gif"
    style="vertical-align:middle" emoid="B)" border="0" alt="cool.gif" /> Stop using those horrible
    colors, fonts and font-sizes. ....
  4. Help Needed To Create Login Script With Perl/cgi
    Need Script (21)
    Have a format in mind and have a good idea how it works. So here what I need: step 1::: person must
    register: create handle // enter password // enter password // enter email : it then takes the
    person to acsepted page or reject per reason page. step 2::: login page: enter handle // enter
    password : takes them on it to the site of their control pages for each handle controls their own
    pages yet all pages interacts with the others. or bad password re login page. Have the page
    designed already have the script in html lang but one can create a password on the html page but....
  5. I Need Help With .htaccess To Create A Login Form
    I need help with .htaccess to create a l (0)
    I want to create a simple html form which submits the information to a processor which in turn
    checks the login and either lets them access the members area or takes them to the login failed
    page. I tried a script which take the username and password and then puts it in the format
    http://username:password@mydomain.com/protected/ bu the problem with that script is that if the
    password is wrong then the login box pops up and this doesnt close even after hitting the cancel
    button about 4-5 times. Is there any better way to secure a members area (an entire folder) withou....
  6. Sockets And Perl
    for a chat script (1)
    Okay, I was trying to write a chat script for perl with tk for the GUI on active perl 5.8. But
    whenever I use the $socket->listen() function to connect to the client, the script always hangs on
    me. Any ideas as to how to avoid this problem (I've tried numerous codes including the one from
    webmonkey).....
  7. Simple Problem W/ Perl
    I can't get this hello world script (5)
    Here's my code: CODE #!/usr/bin/perl # print "Content-type: text/html\n\n"; print "Howdy,
    world!"; I saved it in my cgi-bin with 777 permissions and It goes; QUOTE Internal Server
    Error The server encountered an internal error or misconfiguration and was unable to complete your
    request. Please contact the server administrator, webmaster@supper.astahost.com and inform them of
    the time the error occurred, and anything you might have done that may have caused the error. More
    information about this error may be available in the server error log. Addition....
  8. Perl Script
    (0)
    Hey everyone, got a problem with a Perl script I'm trying out. In my Perl script, I have the
    user input a number to dynamically display a number of text form fields in which they enter figures.
    At the bottom, there will be a button to give the sum of all the numbers in the text
    fields--that's where I'm stuck, I got the text boxes to show up alright, but that's
    about it. I thought I might use JavaScript, but that didn't turn out to well. I was thinking of
    using arrays for the name referencing in the javascript part, but I couldn't figure that out e....
  9. Crypto Program
    A perl "script" to protect data (0)
    If you'd like to protect you doc without the standard program and algorithms you'll fide it
    useful, Now the only big problem is the ARRAY pased to the subs, in fact I can't pass 2 @ at
    the same Sub so I have to use a global array(@plus) in the subroutines, SomeOne knows if is it
    possibile to pass 2 @ to a sub? if yes how? CODE #!/usr/bin/perl #************Random Signature
    V1,0******************# #* CodeName: Crypto v1.7 alpha                     *# #* Coder: K22 -
    www.klakice.astahost.com;         *# #* Date: 07/11/2004;                               ....

    1. Looking for password, reminder, password, change, htaccess, script, change, password






*SIMILAR VIDEOS*
Searching Video's for password, reminder, password, change, htaccess, script, change, password
advertisement




Password Reminder And Password Change .htaccess - I need a script to change password



 

 

 

 

ADD REPLY / Got an Opinion! a humble request :-) RAPID SEARCH! Free Hosting [X]
Express your Opinions, Thoughts or Contribute your information that might help someone here.
Ask your Doubts & Queries to get answers.. "Together, We enlight each other!"
Register FREE for AD-FREE forum, Create your own topics, Ask Questions, track topics, setup subscriptions & notifications and Get a Free Website w/ Email and FTP.
500MB Space *No Ads*, CPanel, FTP, PHP, MySQL, EMails - 100% FREE