Print Page | Close Window

Require Admin activation of new accounts

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=8004
Printed Date: 06 April 2026 at 5:35pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Require Admin activation of new accounts
Posted By: gomjabbar
Subject: Require Admin activation of new accounts
Date Posted: 11 December 2003 at 7:25am
Is there a way to send an email to an admin to approve and active new accounts when they are registered?



Replies:
Posted By: kl8ton
Date Posted: 11 December 2003 at 7:50am
I would be interested in this too.  If you check my post I just put out there you will see why I would be interested in this, the admin could tell who the people are and then assign permissions accordingly.  Great idea!

-------------
Clayton


Posted By: india
Date Posted: 11 December 2003 at 8:07am

Open register.asp and change the code in red

Code:

'******************************************
  '***     Send activate email    ***
  '******************************************

                 'Inititlaise the subject of the e-mail that may be sent in the next if/ifelse statements
                 strSubject = "" & strTxtWelcome & " " & strTxtEmailToThe & " " & strMainForumName

                 'If the members account needs to be activated or reactivated then send the member a re-activate mail a redirect them to a page to tell them there account needs re-activating
                 If (blnEmailActivation = True AND strMode = "new") OR blnAccountReactivate = True Then

                          'Send an e-mail to enable the users account to be activated
                          'Initailise the e-mail body variable with the body of the e-mail
                          strEmailBody = strTxtHi & " " & decodeString(strUsername)
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtEmailThankYouForRegistering & " " & strMainForumName & "."
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtUsername & ": - " & decodeString(strUsername)
                          strEmailBody = strEmailBody & vbCrLf & strTxtPassword & ": - " & strPassword
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtToActivateYourMembershipFor & " " & strMainForumName & " " & strTxtForumClickOnTheLinkBelow & ": -"
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strForumPath & "/activate.asp?ID=" & Server.URLEncode(strUserCode)

                          'Send the e-mail using the Send Mail function created on the send_mail_function.inc file
                          blnSentEmail = SendMail(strEmailBody, decodeString(strUsername), decodeString(strEmail), strMainForumName, mailto:'you@domain.com" - "you@domain.com" , strSubject, strMailComponent, false)


where the email address is yours so you get the confirmation emails



Posted By: india
Date Posted: 11 December 2003 at 8:08am
Thanks Micheal for the code


Posted By: gomjabbar
Date Posted: 11 December 2003 at 9:27am
The code change didn't work.  The mail is still sent to just the user registering.  Any ideas?


Posted By: kl8ton
Date Posted: 11 December 2003 at 9:30am

This did not work for me.  I changed the:

 decodeString(strForumEmailAddress)

to " mailto:me@domain.com - me@domain.com " and the email address entered during the registration process still gets the activate email.  Am I missing something?



-------------
Clayton


Posted By: india
Date Posted: 11 December 2003 at 10:13am

Oops. Sorry this code was by micheal.
anyways, plz try changing this

(strEmailBody, decodeString(strUsername), decodeString(strEmail), strMainForumName, mailto:'you@domain.com" - "you@domain.com" , strSubject, strMailComponent, false)

TO strEmail
to your email address.

meanwhile, i'll try 2 find out a way



Posted By: kl8ton
Date Posted: 11 December 2003 at 11:07am
Is there a way to put in the stored admin email address instead of manually typing in an address?  I am looking at the report_post.asp because those end up going to the forum admin....can we use the same variable?    I really need to get this working today and am trying to help.

-------------
Clayton


Posted By: kl8ton
Date Posted: 11 December 2003 at 12:38pm

Ok, here it is and this works.  The activation email goes to the email address specified and it acts as if it is coming from the person registerings email address and puts their real name (if given) in there too.  You just have to go in, set their group, click on the activate button and send them an email telling them that they are all set!

PS I didn't know if i had to do it in the "activate" and the "welcome" section or not, so i did this in both.

'******************************************
  '***     Send activate email    ***
  '******************************************

                 'Inititlaise the subject of the e-mail that may be sent in the next if/ifelse statements
                 strSubject = "" & strTxtWelcome & " " & strTxtEmailToThe & " " & strMainForumName

                 'If the members account needs to be activated or reactivated then send the member a re-activate mail a redirect them to a page to tell them there account needs re-activating
                 If (blnEmailActivation = True AND strMode = "new") OR blnAccountReactivate = True Then

                          'Send an e-mail to enable the users account to be activated
                          'Initailise the e-mail body variable with the body of the e-mail
                          strEmailBody = strTxtHi & " " & decodeString(strUsername)
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtEmailThankYouForRegistering & " " & strMainForumName & "."
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtUsername & ": - " & decodeString(strUsername)
                          strEmailBody = strEmailBody & vbCrLf & strTxtPassword & ": - " & strPassword
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtToActivateYourMembershipFor & " " & strMainForumName & " " & strTxtForumClickOnTheLinkBelow & ": -"
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strForumPath & "/activate.asp?ID=" & Server.URLEncode(strUserCode)

                          'Send the e-mail using the Send Mail function created on the send_mail_function.inc file
                          blnSentEmail = SendMail(strEmailBody, decodeString(strUsername), "you@domain.com", strRealName, decodeString(strEmail), strSubject, strMailComponent, false)

                          'Reset server Object
                          rsCommon.Close
                          Set rsCommon = Nothing
   adoCon.Close
   Set adoCon = Nothing

                          'Redirect the reactivate page
                          If blnAccountReactivate = True Then
                                   Response.Redirect("register_confirm.asp?TP=REACT&FID=" & intForumID)
                          'Redirect to the activate page
                          Else
                                   Response.Redirect("register_confirm.asp?TP=ACT&FID=" & intForumID)
                          End If


  '******************************************
  '***     Send welcome email    ***
  '******************************************

                 'Send the new user a welcome e-mail if e-mail notification is turned on and the user has given an e-mail address
                 ElseIf blnEmail = True AND strEmail <> "" AND strMode = "new" Then

                          'Initailise the e-mail body variable with the body of the e-mail
                          strEmailBody = strTxtHi & " " & decodeString(strUsername)
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtEmailThankYouForRegistering & " " & strMainForumName & "."
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtEmailYouCanNowUseTheForumAt & " " & strWebsiteName & " " & strTxtEmailForumAt & " " & strForumPath
                          strEmailBody = strEmailBody & vbCrLf & vbCrLf & strTxtUsername & ": - " & strUsername
     &nbs

-------------
Clayton




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net