Author |
Topic |
|
jesusdaniel
Starting Member
5 Posts |
Posted - 09 November 2002 : 19:39:45
|
How do I get the MEMBER_ID in a variable like
intmemberid = Request.Cookies("ID")
Is for another page thet I'm doing, but wanna catch the MEMBERID in a variable to make SQL and show members dateails in other pages, like a Mini-Perfil |
Edited by - ruirib on 13 November 2002 08:42:52 |
|
ruirib
Snitz Forums Admin
Portugal
26364 Posts |
|
jesusdaniel
Starting Member
5 Posts |
Posted - 10 November 2002 : 21:18:11
|
is the only way to get de logged MEMBERID ?, i don wanna show the navigation, titleimage, and form, just wanna get the logged MEMBERID... if I include that file, it change my design, font ype, bgcolor etc... :( ... |
|
|
jesusdaniel
Starting Member
5 Posts |
Posted - 10 November 2002 : 21:35:17
|
I mean, the page I'm doing is in the main directory, the inc_header is in foros/inc_header.asp , In the main directory I have a file called common.asp where I catch some details of the logged user, to show the miniperfil in the main page, and the username y other pages that differs from forum :/ .
plz |
|
|
DoraMoon
Average Member
Taiwan
661 Posts |
Posted - 10 November 2002 : 21:35:45
|
the MemberID defined in chkUser function. (inc_func_common.asp) i'm not sure is it anothre simple way to get member id... but i think you can try this... copy the chkUser function(or just including the inc_func_common.asp to your page.) and add below this line to your page..
mLev = cLng(chkUser(strDBNTUserName, Request.Cookies(strUniqueID & "User")("Pword"),-1))
then i think you'll can just use MemberID to get what you need.
no test, no sure it'll work.. |
Edited by - DoraMoon on 10 November 2002 21:39:55 |
|
|
jesusdaniel
Starting Member
5 Posts |
Posted - 10 November 2002 : 23:57:16
|
something happen with the types
No coinciden los tipos: 'chkUser'
is like Type Mismatch: 'chkUser'
thanx |
|
|
DoraMoon
Average Member
Taiwan
661 Posts |
Posted - 11 November 2002 : 06:20:49
|
hi~ jesus, would you have the config.asp including in that page ? to make this way work, i think maybe you'll also need to do this.. <!--#include file="config.asp"--> <!--#include file="inc_func_common.asp"-->
and may i ask why you'll need the Member ID value?? i know we can just get the User name/password from cookie easily, but the MemberID... seem a lots difficult to do this.... |
|
|
ruirib
Snitz Forums Admin
Portugal
26364 Posts |
Posted - 11 November 2002 : 18:07:01
|
quote: Originally posted by DoraMoon
hi~ jesus, would you have the config.asp including in that page ? to make this way work, i think maybe you'll also need to do this.. <!--#include file="config.asp"--> <!--#include file="inc_func_common.asp"-->
and may i ask why you'll need the Member ID value?? i know we can just get the User name/password from cookie easily, but the MemberID... seem a lots difficult to do this....
If you have the username and password getting the ID is just a matter of executing a simple query on the FORUM_MEMBERS table... |
Snitz 3.4 Readme | Like the support? Support Snitz too |
|
|
jesusdaniel
Starting Member
5 Posts |
Posted - 12 November 2002 : 14:37:26
|
quote: Originally posted by DoraMoon
hi~ jesus, would you have the config.asp including in that page ? to make this way work, i think maybe you'll also need to do this.. <!--#include file="config.asp"--> <!--#include file="inc_func_common.asp"-->
and may i ask why you'll need the Member ID value?? i know we can just get the User name/password from cookie easily, but the MemberID... seem a lots difficult to do this....
Yep I have that 2 files included, and I get that error... I need the memberid to... Is for another page thet I'm doing, but wanna catch the MEMBERID in a variable to make SQL and show members dateails in other pages, like a Mini-Perfil, There I'm going to show the Location, num of post and the username, no more, in other directory...
default.asp /foros/... (here are the snitz) /imagenes/ /fotos/
etc... in that default.asp is the miniperfil :( |
Edited by - jesusdaniel on 12 November 2002 14:45:39 |
|
|
DoraMoon
Average Member
Taiwan
661 Posts |
Posted - 13 November 2002 : 07:45:08
|
well~ i'm no idea about this any more.... maybe also try add these two lines above the mLev = ........ strUniqueID = "Snitz00" strDBNTUserName = Request.Cookies(strUniqueID & "User")("Name")
the basic rule is you get username from cookie first, then by ChkUser function, as ruirib mentioned, i think that function just do a simple query from MEMBERS table to get member level and member id.
but i know it not just as simple as my innocent thought... just waiting, i'm sure someone else can help you do this. |
|
|
ruirib
Snitz Forums Admin
Portugal
26364 Posts |
Posted - 13 November 2002 : 08:42:28
|
Look, if you're having problems getting the MEMBER_ID and you can get the username and password from the cookie, just use them in the query to get all the member info you want (including MEMBER_ID). I would change the forum settings so that cookies are set to WebSite and not forum, read the cookies to get the user name and password as done in inc_header.asp and then use them as query criteria to get the user info.
I'm moving this to the MOD W/O Code forum. |
Snitz 3.4 Readme | Like the support? Support Snitz too |
|
|
havvoc
New Member
92 Posts |
Posted - 16 November 2002 : 14:20:17
|
? I read this question different, if your asking the path to your forum directory from your foros/ directory. try " ../ " (wo/quotes)
|
|
|
|
Topic |
|