Leverage existing authentication - Posted (1361 Views)
Starting Member
web guy
Posts: 21
21
Hello, is it possible to use the existing forum authentication system on a custom web form.

I use the Snitz Forum for my building condominium association.
I need to create a system for my users to submit maintenance requests. I would like to use the existing Snitz authentication to capture username for each request and send it to a new table. Does anyone know which include files I need to add to a blank asp page which would allow me to grab snitz variables and also maintain security.

 Sort direction, for dates DESC means newest first  
 Page size 
Posted
Advanced Member
Carefree
Posts: 4224
4224
Sure, you'll need to include these three:
"config.asp", "inc_sha256.asp", "inc_header.asp"
Posted
Snitz Forums Admin
ruirib
Posts: 26364
26364
Definitely config.asp, inc_sha256.asp and inc_func_common.asp. inc_header.asp isn't strictly needed, as long as some of the code there is used in your page.
Posted
Starting Member
web guy
Posts: 21
21
Thanks guys, perfect! Sorry I didn't respond sooner bigsmile
Would then I just use Request("username"), Request("email") to get the values?
Posted
Advanced Member
Carefree
Posts: 4224
4224
Code:

Response.Write	"User Name="&strDBNTUserName
Response.Write "EMail="&strEMail
Your values, therefore, can be retrieved using the two str values.
Posted
Starting Member
web guy
Posts: 21
21
Thank you Carefree cool
Got it~
Posted
Support Moderator
Shaggy
Posts: 6780
6780
The e-mail address is not stored in a variable, you'll need to create your own and modify the chkUser function accordingly.
Search is your friend “I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Posted
Advanced Member
Carefree
Posts: 4224
4224
I forgot, I added that a long time ago.
Ok to get the EMail from the database

Code:

strSql="SELECT M_EMAIL FROM " & strMemberTablePrefix & "MEMBERS WHERE MEMBER_ID="&MEMBERID
set rsMail=my_Conn.Execute(strSql)
if not rsMail.EOF then
strEMail=rsMail("M_EMAIL")
end if
Response.Write strEMail&"=strEMail"
Posted
Starting Member
web guy
Posts: 21
21
Ok guys, thanks for all the support. I will give it a go this afternoon.
 
You Must enter a message