Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Seeking applications ...
Author Message
Caedus
Hangin' Around



Joined: Jun 21, 2004
Posts: 39
Location: The Netherlands

PostPosted: Mon Jun 21, 2004 11:43 am Reply with quote

Quite simple question. When an user has forgotten his/her password then the "Your_Account" module gives him/her the possibility to retrieve, by entering the corresponding username.

This gives one problem: when the user doesn't know the USERNAME then the password problem can only be solved by mailing the webmaster with the question to look things up. And every webmaster wants to keep help-mails at a minimum I think Rolling Eyes .

At my websites I've kept the memberlist restricted so only logged in users can view it, but even if it was publicy available then searching for a name isn't the right way.

My suggestion: give the user the oppurtunity to enter an emailadres in the "Forgot Password?" area, because e-mails are almost never forgotten.

So, is this doable and would someone like to help people like me with it?

[EDIT]
One small note: I've nuke 6.9 and I don't know how much the newest versions of the Your_Account module differ from each other.

_________________
Arrow Caedus
RavensScripts 
View user's profile Send private message Send e-mail Visit poster's website MSN Messenger
Raven
Site Admin/Owner



Joined: Aug 27, 2002
Posts: 17088

PostPosted: Tue Jun 22, 2004 6:57 am Reply with quote

Try this. Now I have used 7.1 but 6.9 will be very similar if not the same. I have only briefly tested this too. But, it seemed to work. It will get you very close in any event. You will probably want to add the verbiage to a language file instead of hard coding it as I did.

In Your_Account/index.php find
Code:
function pass_lost() {
Then find the first occurrence of
Code:
       ."<table border=\"0\"><tr><td>\n"

           .""._NICKNAME.":</td><td><input type=\"text\" name=\"username\" size=\"15\" maxlength=\"25\"></td></tr>\n"
and change it to
Code:
       ."<table border=\"0\"><tr><td>\n"

           .""._NICKNAME.":</td><td><input type=\"text\" name=\"username\" size=\"15\" maxlength=\"25\"></td></tr>\n"
           ."<tr><td>\nor</td></tr>"
         ."<tr><td>\n".""."E-mail Address that you registered with".":</td><td><input type=\"text\" name=\"user_email\" size=\"50\" maxlength=\"255\"></td></tr>\n"

Then find
Code:
function mail_password($username, $code) {

    global $sitename, $adminmail, $nukeurl, $user_prefix, $db, $module_name;
    $sql = "SELECT user_email, user_password FROM ".$user_prefix."_users WHERE username='$username'";
    $result = $db->sql_query($sql);
    if(!$result) {
   include("header.php");
   OpenTable();
   echo "<center>"._SORRYNOUSERINFO."</center>";
   CloseTable();
   include("footer.php");
    } else {
   $host_name = $_SERVER["REMOTE_ADDR"];
   $row = $db->sql_fetchrow($result);
   $user_email = $row[user_email];
   $user_password = $row[user_password];
and change it to
Code:
function mail_password($username, $code, $user_email) {

    global $sitename, $adminmail, $nukeurl, $user_prefix, $db, $module_name;
   if (empty($user_email)) {
       $sql = "SELECT user_email, user_password FROM ".$user_prefix."_users WHERE username='$username'";
   }
   else {
       $sql = "SELECT user_email, user_password, username FROM ".$user_prefix."_users WHERE user_email='$user_email'";
   }
    $result = $db->sql_query($sql);
    if(!$result) {
   include("header.php");
   OpenTable();
   echo "<center>"._SORRYNOUSERINFO."</center>";
   CloseTable();
   include("footer.php");
    } else {
   $host_name = $_SERVER["REMOTE_ADDR"];
   $row = $db->sql_fetchrow($result);
   $user_email = $row[user_email];
   $user_password = $row[user_password];
   if (!empty($user_email)) $username = $row[username];

Lastly, find
Code:
    case "mailpasswd":

   mail_password($username, $code);
   break;
and change it to
Code:
    case "mailpasswd":

   mail_password($username, $code, $user_email);
   break;
 
View user's profile Send private message
Caedus







PostPosted: Tue Jun 22, 2004 8:36 am Reply with quote

Thanks for your efforts! It works fine now with entering an emailadres, but I've still two problems:

1. When I enter a non-existent emailadres, it says that the password is mailed. This could be fixed quickly I think.

2. When entering the user-name, it says that the username can't be found.

As for point two I think the problem lies in this piece of code:

Code:
function mail_password($username, $code) {

    global $sitename, $adminmail, $nukeurl, $user_prefix, $db, $module_name;
    $result = $db->sql_query("SELECT user_email, user_password FROM ".$user_prefix."_users WHERE username='$username'");
    if($db->sql_numrows($result) == 0) {
   include("header.php");
   OpenTable();
   echo "<center>"._SORRYNOUSERINFO."</center>";
   CloseTable();
   include("footer.php");
    } else {
   $host_name = $_SERVER["REMOTE_ADDR"];
   $row = $db->sql_fetchrow($result);
   $user_email = $row['user_email'];
   $user_password = $row['user_password'];


That is the original index.php code from the nuke 6.9 Your_Account module. As you can see there is a slight difference in the sql queries in the beginning of the code.

So I think that the versions 6.9 and 7.1 aren't identical and there are minor differences in the rest of the index file.

Could you please take a look at the code of 6.9 and perfectionise this?
 
Caedus







PostPosted: Fri Jul 02, 2004 12:15 pm Reply with quote

*bump*
 
Raven







PostPosted: Fri Jul 02, 2004 1:27 pm Reply with quote

I sometimes reach a point of leading a horse to water ......

When tweaking becomes writing or rewriting a script, that's when I usually have to prioritize my time between handouts and earning a living Wink (no offense intended)
 
Caedus







PostPosted: Sun Jul 04, 2004 5:22 am Reply with quote

That means I should figure it out myself. Bleh Sad . I'll try, but I suck at php-programming.
 
Raven







PostPosted: Sun Jul 04, 2004 7:24 am Reply with quote

Feed a man a fish and you feed him for but a day. Teach a man to fish and you feed him for a lifetime Wink .
 
SmackDaddy
Involved
Involved



Joined: Jun 02, 2004
Posts: 268
Location: Englewood, OH

PostPosted: Sun Jul 04, 2004 1:45 pm Reply with quote

Would be nice to see someone script an "addon" of sorts to modify it so that a user could enter USERNAME or EMAIL to retrieve password.....
 
View user's profile Send private message Send e-mail Visit poster's website
Raven







PostPosted: Sun Jul 04, 2004 3:46 pm Reply with quote

Uh, that's what I did in my original reply above.
 
Caedus







PostPosted: Sun Jul 04, 2004 4:02 pm Reply with quote

lol, SmackDaddy got owned Razz

And yes Raven, you are right with that saying. Anywayz, great job and even if I don't succeed then I just remove the username part Cool .
 
SmackDaddy







PostPosted: Sun Jul 04, 2004 4:17 pm Reply with quote

Raven wrote:
Uh, that's what I did in my original reply above.


But he said when entering a username, it doesn't work....and no, not all of us are programmers.......which is why you run a site such as this and people come to you. Just as you use all those adages, I will use one:

"We can be some things to some people, but we cannot be all things to all people" (or however that goes)

So no Caedus, I did not get owned.....it still would be nice for that to be done AND working. Which apparently it doesn't as Raven also suggests by telling the guy to fix it himself..... Rolling Eyes

And no offense Raven, but it seems as of late, you are rather a bit annoyed at helping people or doing coding, as a few of your posts are simply telling people really to figure it out for themselves, but not all people are programmers. At 33 and having taken SEVERAL programming classes, I can tell you I am not programmer material and rely on the skills of others the same way you might rely on an auto mechanic's skills to fix your car or assess an issue. (just an example there) If you are irritated or burnt out, might I suggest taking a break or not replying to people's posts and allowing others to help? When others see Raven tell someone to figure it out, do you think they are going to walk on your toes and tell them how to do it? Doubt it.....I definitely wouldn't donate to a help site that's merely telling me to figure it out for myself.

Again, I am not trying to offend, but in the last few weeks of being here, I am merely saying what I see, but then again, I don't know you so that's all I can do, right?

Thank you for your time and your coding skills and your site.....seriously. I do mean that.
 
Raven







PostPosted: Sun Jul 04, 2004 5:24 pm Reply with quote

SmackDaddy,

I run a site, such as this, to offer scripts and help, IN MY SPARE TIME, non-gratis. And in spite of your intentions, this post is very offensive. If you feel the need and/or the right to take me or anyone else here to task, then have the courtesy and maturity to do it in private. If I or any other person here suggest to someone to figure it out, it is because we believe that we have provided enough foundation to do so or we may believe that someone is busting our balls. And if that is not the case then the person can simply post back and say "I tried and it didn't work". I also operate this site at MY EXPENSE. Several hundred kaching!$/month. I do not get anywhere even close to that nor do I ask. If you sense I am annoyed, this time you are correct. And because you don't know me that is NOT all you can do. As I said, you might have contacted me in private and offered to help, rather than just critisize publicly.


Last edited by Raven on Sun Jul 04, 2004 10:44 pm; edited 1 time in total 
Nukeum66
Life Cycles Becoming CPU Cycles



Joined: Jul 30, 2003
Posts: 551
Location: Neurotic, State, USA

PostPosted: Sun Jul 04, 2004 6:12 pm Reply with quote

I'm sorry you feel as you do. But Raven has helped and more than likely will continue to help hundreds of people. In what I've read in the above post he provided you with more than enough information to get this going on your own.

SEARCHING and READING the forums........... Wink

I hope you do take offense to this, but if you don't like it here go somewhere else!

_________________
Scott Johnson MIS Ubuntu/Linux 11.10

Last edited by Nukeum66 on Sun Jul 04, 2004 10:28 pm; edited 2 times in total 
View user's profile Send private message Visit poster's website
sixonetonoffun
Spouse Contemplates Divorce



Joined: Jan 02, 2003
Posts: 2496

PostPosted: Sun Jul 04, 2004 6:25 pm Reply with quote

SmackDaddy wrote:
Would be nice to see someone script an "addon" of sorts to modify it so that a user could enter USERNAME or EMAIL to retrieve password.....


Try the hack I posted here: [ Only registered users can see links on this board! Get registered or login! ]

Let us know how it goes. Your version may be slightly different. Not trying to be a wise arse but search is very useful on support forums.
 
View user's profile Send private message
chatserv
Member Emeritus



Joined: May 02, 2003
Posts: 1389
Location: Puerto Rico

PostPosted: Sun Jul 04, 2004 6:52 pm Reply with quote

I had written something else but it got too extensive for a forum post so i'll limit myself to saying what has already been said, we do this for free and on our own free time, we have our own projects and many times we have to put them on hold so we can devote time to helping others, the help sometimes can take some time to arrive and in some cases it might not be as complete as a person expects but it gets delivered, i for one like what i do and while (with a few exceptions) i don't make a dime out of it i still give it my best with the only limitation being the time i have for it, in the past few days i have been a bit sidelined because of health problems but i still find the time to do a bit of online work. The very same thing applies to Raven and the many others that spend most if not all of their online time helping out the community.
 
View user's profile Send private message Visit poster's website
SmackDaddy







PostPosted: Sun Jul 04, 2004 6:57 pm Reply with quote

And I run a site for free in my spare time provide free tech support. I fully understand Raven.....despite you thinking I don't. As stated, my intention wasn't ill, and I apologize that it was taken as such. I speak my mind and ask Bob, I do take things to people in private that I feel the need to take in private....I was commenting on what seemed to be a decline in "pleasure" or "happiness" in doing what you are doing. I will keep my comments to myself in the future. Sorry for stirring the pot. Seems like I am making enemies where that's not the intention. Guess I will moderate my feelings unlike what you all did on Nukecops.

Raven, I apologize for the speaking up in your forum. Next time I have anything to say that could be disagreeable by anyone on the site, I will send it to you in private for approval.
 
SmackDaddy







PostPosted: Sun Jul 04, 2004 7:00 pm Reply with quote

sixonetonoffun wrote:
SmackDaddy wrote:
Would be nice to see someone script an "addon" of sorts to modify it so that a user could enter USERNAME or EMAIL to retrieve password.....


Try the hack I posted here: [ Only registered users can see links on this board! Get registered or login! ]

Let us know how it goes. Your version may be slightly different. Not trying to be a wise arse but search is very useful on support forums.


Thank you six, I will look into that. Much obliged.
 
chatserv







PostPosted: Sun Jul 04, 2004 7:15 pm Reply with quote

SmackDaddy wrote:
Guess I will moderate my feelings unlike what you all did on Nukecops.

Trust me on this, a lot had to be said and it could have but it wasn't, there's more to that place than what people will ever know, the only time someone like me opened his mouth back there it was to defend myself against cheap blows, the rest remained with me and it will remain that way.
 
SmackDaddy







PostPosted: Sun Jul 04, 2004 9:34 pm Reply with quote

Understood Chatserv. I guess I haven't been around long enough to have an opinion here that could be contrary to others. As stated, I wasn't intending to upset, just pointing out what I see. And I meant what I said about keeping quiet tho....I wasn't being facesious. But if people are going to get their feather's ruffled and stay that way, then I am sure a negative attitude can be taken from anything I write if one looks hard enough from this point forward....regardless of my intent. I feel I have worked myself into a "Darned if I do, darned if I don't" position now, especially since many feel the need to come to Raven's aid from "SmackDaddy's barrage of ill-will". Rolling Eyes Ah well.... although once should be enough, this is the last time I will say it: Sorry Raven.
 
JediStryker
Hangin' Around



Joined: Jun 27, 2004
Posts: 38
Location: San Antonio, TX

PostPosted: Sun Jul 04, 2004 9:36 pm Reply with quote

I hate to see these things taken down this path. I too am not a programmer, but if Raven or Chatserv (didn't know you were posting here! Two geniuses here! Amazing!) don't get back to me, I realize that they're probably busy and don't comment.

There are hundreds of people asking for hundreds of things; this isn't an emergency, so why assume that just because they don't hold your hand down the path, they're upset or tired of the job?

I have helped a lot of people with computer/networking issues on a site I frequent. After a few times answering the same questions over and over again, I get tired of it. But I still help them. If a few of their questions are unimportant, then I will point them in the direction they need to go, and let them take it from there.

Normally I get paid $80 an hour for the work I do, yet I do it for some for free. Why should I have to hold all their hands all the time?

I don't know, I'm sorta on a 4th of July buzz right now, so maybe one of the staff here will feel the need to edit or delete this post. Hope it makes as much sense to you as it does to me! Wink
 
View user's profile Send private message Send e-mail Visit poster's website AIM Address
chatserv







PostPosted: Sun Jul 04, 2004 10:04 pm Reply with quote

Don't take me wrong SmackDaddy, i have no issues with you, my first post was to deliver a point across that many seem to overlook (you'd be amazed at what we see via pm's and emails) and the second one was only to clarify any part that may have involved me (even if unintentional),none of this is directly aimed at one person. Anyway i think i see your point, it's like i more or less said, many don't know what takes place behind the scenes so they jump to conclusions. As for Raven i can vouch he has a lot on his plate work-wise plus there's always that thing everyone talks about, i think they call it real life, for some of us it has been a bit hectic to say the least.

P.S. JediStryker i hope you don't mind that i took those two bottles of Tequilla Cuervo you had stashed in the kitchen, i'm only doing you a favor. (just kidding, hiyas pal)
 
Raven







PostPosted: Sun Jul 04, 2004 10:09 pm Reply with quote

SmackDaddy,

I never said you didn't understand. And I have reread your post several times. It isn't that you have to earn a right to post your opinion either. However, before presupposing what is and isn't, it is good to get to know the site keepers a little better. This site has many outspoken people and I don't get my feathers ruffled easily. If you think that then you are correct in that you don't know me. As to the remark about NC, as Chat said, you don't know the half of what was going on there. There was a day, just about a year ago, when Nuke Cops was maintained by Chatserv, AtificialIntel, Six, Raven, and maybe a couple others, occasionally. Chat, Raven, and Six are now here (and have their own sites too). AI is with Bob Marion. I doubt that any of us will ever tell the stories, but suffice it to say, there is no comparison with this thread.

You are free to and I encourage you to, speak your mind. But when you start suggesting that I may be burned out and I am this or that, that's getting too personal, imo. Count how many times I flat out tell anyone to go figure it out. If there are any, there aren't many. I usually try to lead and suggest before giving solutions, especially in light of what Chat has said about our own projects and such.

Finally, I am not offended but took offense. I am passed that and to me we spoke our peace so let's move on Smile - Hope you had a great 4th celebration, if you celebrate the 4th!
 
jaded
Theme Guru



Joined: Nov 01, 2003
Posts: 1006

PostPosted: Sun Jul 04, 2004 10:58 pm Reply with quote

Quote:
Guess I will moderate my feelings unlike what you all did on Nukecops.

Raven, I apologize for the speaking up in your forum. Next time I have anything to say that could be disagreeable by anyone on the site, I will send it to you in private for approval.


Are you kidding me with that? For a man who was supposed to be saying he was mistaken you sure found a way to slap them in the face again. I for one think so very highly of Raven,Chat, and the others here that I find your SNIDE remarks offensive.
You took it upon yourself to publicly criticize the way that this site is run. You clearly said that "you have noticed that recently Raven(personally) has been short with people, annoyed with them. That he has told many people (as nicely as he can) that they need to find the answer themselves. Well, of course he did! He provided a great deal of information for that person to use. It was working but for him to modify the entire code to suit one person would be HIGHLY time intensive. They have many posts to help with. If that person tried to work the code, did some research, and searched for the answers I am certain that he would get it to work just as he wants.
You are both misinformed and arrogant with your attitude in your posts. you stated that you should no longer speak if you have a resenting opinion well that is just CRAP! You intended exactly what you wrote and exactly the way it was perceived. You made a judgment about all of us who spoke up to defend this site and the ones who run it. You stated that "from now on if your opinion is different from the ones of the people on this site. you will just keep your mouth shut" well, that is offensive. You sound like a person who made a VERY critical judgment about this site. Perhaps if you feel it is not helpful you should just LEAVE. No one here is ever told that they cannot speak their mind. However, saying what you wanted to say would have been more appreciated had you sent it directly to Raven in pm!
You were open in making your comment about nuke cops as well. I find that laughable. With your "eye rolling", that shows that you are obvious bias toward some of the people on this site. Your posts have a VERY sarcastic tone to them which again I find truly offensive. There is no need for that. I personally liked nuke cops until I felt that they crossed a line. For a person who says he has only been coming to this site for a couple of weeks you SURE seem to have a great big negative opinion of this site in its handling of the nuke cops issues. I find that curious Wink
Perhaps this site is not the one for you. That is something that you should consider as you do not seem to care for the people on it Idea I would hope that you exercise better judgement the next time you decide to ridicule someone who has given tirelessly of his time, money, and skill to help an entire community. Have a great night SMACKDADDY Rolling Eyes << you are not the only one who can be sarcastic

_________________
Themes BB Skins [ Only registered users can see links on this board! Get registered or login! ]
Graphic Tees [ Only registered users can see links on this board! Get registered or login! ]
Paranormal Tees [ Only registered users can see links on this board! Get registered or login! ]
Ghost Stories & More [ Only registered users can see links on this board! Get registered or login! ] 
View user's profile Send private message Visit poster's website
SmackDaddy







PostPosted: Mon Jul 05, 2004 1:46 am Reply with quote

Raven wrote:
Finally, I am not offended but took offense. I am passed that and to me we spoke our peace so let's move on Smile - Hope you had a great 4th celebration, if you celebrate the 4th!


Understood. And hopefully we *can* get past it.....if you are passed it, then hopefully, those around you (and protecting you) can get past it as well. (Raven's a big boy people, sheesh). So much is being read INTO...but I am just as at fault for my analytical "sitting back and reading the forums DAILY" approach and speaking on what I have seen over the last couple of weeks.

Raven, thank you for your time and site.....again, people can read into my black and white text all they want, to others, I'm done with this and according to Raven he is too.
 
baloo
Hangin' Around



Joined: Sep 10, 2002
Posts: 30

PostPosted: Mon Jul 05, 2004 3:11 am Reply with quote

I did have a long and drawn out rant ready to post but then realised everyone has kissed and made up, apologised, and go on with life so I've had to delete my work of forum art Wink

Anyway, let me just add that I have yet to come across someone who has been more helpful, accomodating and willing to teach than Raven. As he has pointed out in another thread, I've been badgering Raven for a couple of years now and he has always responded promptly and with good will in his heart.

So, now that the love fest is over, which site do I have to go to in order to get a stand alone "Waiting Content" block ? Bang Head Laughing
 
View user's profile Send private message
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Seeking applications ...

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©