473,398 Members | 2,393 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

Resend password function

Hi there,

I am trying to create a 'resend password' function as my members get a little confused sometimes (just as I am now!)...ah the irony!

In any case, the below code gets me to my output html template, however; I also want it to send details to the member via e-mail.

The below code gives me an e-mail and information in the subject line... but I don't know how to get information from let's say a .txt template with the message I want to say. any advice?

Here's the part that actually work's: go to www.yourstocktips.com.au/forgotpass.htm and type in "Nala" as the user name (dummy account).

Thanks!

OzNewbie

Here's the code:
Expand|Select|Wrap|Line Numbers
  1. ###############################
  2. # Send password
  3. ###############################
  4. sub pm_send_password
  5. {
  6.  open (DATABASE, "<${root}$database") or print $!;
  7.  if($flocking) {flock DATABASE, 2;}
  8.  
  9.  while(($thisrow = <DATABASE>))
  10.  {
  11.     if ($thisrow =~ m/^$input{'login'}\|(.*)/)
  12.      {
  13.      &init($thisrow);
  14.     &sendemail($values{'email'}, $from, $subject_lost_password, &tempwiz_to_from);
  15.      $sent = 1;
  16.      }
  17.  }
  18.  if($flocking) {flock DATABASE, 8;}
  19.  close DATABASE; 
  20.  if(!$sent){&init_errors; &err($error_message{'login not found'});exit;}
  21.  $input{'action'} = "lost_password_sent";
  22.  &tempwiz;
  23.  exit;
  24. }
  25.  
Nov 15 '09 #1
2 1741
RonB
589 Expert Mod 512MB
Cross posted: http://perlguru.com/gforum.cgi?post=...=unread#unread
Nov 15 '09 #2
numberwhun
3,509 Expert Mod 2GB
Thanks RonB for the heads up.

So, did the answer(s) that you received in the PerlGuru forum help you solve this issue?

Regards,

Jeff
Nov 17 '09 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: MLH | last post by:
What's the simplest way to allow a user of an A97 app to change password?
1
by: Bill Davidson | last post by:
(RESEND: I added a little more code to the sample for clarity) Hello All: I've got a question about synchronization requiremements in a C# worker thread procedure that, among other things,...
9
by: kwindham | last post by:
This program doesn't seem like it should be too hard, but I cannot figure it out. Here is the assignment: Password Verifier - Write a program to verify passwords, satisfying the following...
0
by: serkan | last post by:
Guys, I am trying to get this password reset functionality wor for me but I am not successful at all. Please somebody help me. I get "Your password could not be reset - please try again later" so I...
10
by: phforum | last post by:
Hi, I wrote a PHP page for user input the information to search the database. And the database data will update every second. I want to set the auto refresh to get the data from database every...
11
by: Kevin O'Brien | last post by:
Hello, I am creating a sign on screen for my application in which I want to store the username and password in a database table. I was thinking of putting a combo box connected to the database...
2
by: DarthPeePee | last post by:
Hello everyone. I am working on a Password Strength Meter and I am running into 1 problem that I would like to fix. When pressing the "Clear Password & Try Again" button, the password clears...
4
by: =?Utf-8?B?QXNhZg==?= | last post by:
Hi, How can I prevent from an ASP.NET page to resend all the data again when the user press the Refresh button or F5 on the browser? Thanks in advanced, Asaf
5
by: agun | last post by:
Hi, guys sorry if this kind of question had been asked before and kinda newbie question. coz i'm new to programming and just couldn't figure it out yet... My problem is: I have a form that...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.