News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Displaying Username in Approval Email?

Started by KidGuko, May 17, 2006, 06:52:33 PM

Previous topic - Next topic

KidGuko

I am trying to modify the approval email in Login.english.php. I have gotten most of it completed, but I am having an issue getting the users name to show up in the email. I found a thread in search that that said I sould use %2$s or it might have been %2&s...cant remember which it was but I tried using both. I still can not get the user name to show. I used $context['user']['name'] cause I thought it would be similar to $context['forum_name'] but this only showed the username of the person who sent the email and not the recipient. Can anyone help me out with this? What code do I need to use to display the username in the email of the user I am trying to approve?

Thanks
KidGuko

KidGuko

I really need some help with this if anyone knows what to do. I manage a forum for my boss and well, he is getting annoyed at me today cause what seems to be a minor task is not as minor as he would think. How can I do this?

Leipe Po

There is only one thing more importend to me then coding:
My Girlfriend

Microsoft - "You've got questions.  We've got dancing paperclips."

KidGuko

#3
Quote from: Leipe Po on May 18, 2006, 06:37:13 PM
try to use $_POST['user']

Tried it already. It returned null.

Here is the text I am editing (with some proprietary information edited out with ****** in its place):

$txt['admin_approve_accept_desc'] = 'Your application has been accepted and your Forum account has been activated; you can now login and post messages.

In order to begin Beta Testing you must next create a ****** account; here are the steps:
       
A) Browse to ****** and click 'Play Now' on the homepage. 
       
B) Fill out the \'Create Your ****** Account\' form.  As your Screen Name, enter
' . $_POST['user'] . ' (the same name you used to register in the Forum). 
Be _very_ careful to enter your screen name exactly as it is shown here, including
capitalization; if you make a mistake it will prevent you from playing the unreleased
games that Beta Testers normally have access to.
       
C) If your chosen screen name is already taken, please choose another screen name. 
Then send an email to ****** saying "My Forum name is ' . $_POST['user'] . ',
but that name was already taken as a ****** screen name.  My new screen name is
\'(whatever name you chose)\'."

Be _very_ careful to use the correct capitalization for your screen name in the letter. 
When I receive this letter I will change your Forum name to match your ******
screen name (and you will get an email notifying you of the change).
       
D) Please use the same email address to register in ****** that you used to register
here in the Forum.  This is VERY IMPORTANT; it helps us connect your ******
account with your Forum account.  These accounts are in two separate databases; we
must have an email address that is the same in both places in order to connect the
two.
       
E) Click \'Continue\'.
       
F) The next screen is \'Billing Information\'.  In the top left quarter of this screen there is
a field labeled \'Enter Code:\'  Enter this code: \'******\' in the field and click \'Apply\'. 
Just entering the code is not enough; YOU MUST ALSO CLICK \'APPLY\'.  Please don\'t
give this code to anyone else.
       
G) Fill out the \'Billing Information\' form and click \'Continue\'. If you have done the previous
step correctly you won\'t be asked for a credit card number.
       
H) Review your entries and click \'OK\'.

I) Sign into the Beta forum (at ******) and read the
bulletins, particularly the one titled \'How to Download the Beta Version\'.  Be sure to
write down the password; you will need it to complete the installation.  Download and
install the Beta version.</li>
       
J) Play!

    When you first login you will have a catalog of about 500 games; once we set the \'Beta Tester\' flag on your account you will have access to about 600 games.  Please be patient, it could take a week from the time your registration is approved to the time you have access to the additional games.  If it takes more than a week then you may post a message in the forum and ask for a status update.

    We look forward to your help testing out the latest and greatest versions of ******.  You can look forward to more new games, entire new gaming platforms, a bunch of exciting new features, and loads of fun.

    Here\'s to fun!

******
Lead QA Analyst – ******
******

================================

';


I have used %2$s as I saw another in the forums use (maybe he set something up different?) and it just displays %2$s in the email and nothing special. I have used $context['user']['name'] and this displays the username of the user that initiated the email...in my case me (the admin). I have used $_POST['user'] and have gotten a null value with it. This is still stumping me...maybe [unknown] can step in and help out, :) lol. Really I dont care who helps out...as long as it may help me get to the goal I desire. Thanks for your reply Leipe Po...but I just forgot to mention that I had already tried $_POST['user']. Oh, I have also used $row['memberName'] but somehow I knew that would not work (I think I may have to create a db call since I am trying to call the username from a differ file than the register.php file?). Well, I will keep trying and maybe I will get a solution before I get an answer. If I do I will post that I found out how to do it...if I dont post then, well, I still need help.


Thanks

KidGuko

Is there no one that can help? I am sure someone has done this in the past...?

Thanks

Leipe Po

i will look into it tommorow, maybe make a little mod of it...
There is only one thing more importend to me then coding:
My Girlfriend

Microsoft - "You've got questions.  We've got dancing paperclips."

KidGuko


Advertisement: