Print Page | Close Window

how to login user with HTTPXML API?

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=28710
Printed Date: 01 April 2026 at 7:42pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: how to login user with HTTPXML API?
Posted By: tjodalv
Subject: how to login user with HTTPXML API?
Date Posted: 17 July 2010 at 5:18pm
Hi

I just downloaded copy of Webwizforums, and I want to keep my users in WWF database, but I want to have my own login and registration form.

I created my login form, so basically i want to check if user exists in WWF database, and if exists then log in user.

I am using LoginMemberCookie method, and i get this response:

<ApiResponse> 
 <ErrorCode>0</ErrorCode> 
 <ErrorDescription/> 
 <ResultData recordcount="1"> 
  <Record> 
   
   <Username>Administrator</Username> 
   <UserID>1</UserID> 
   <CookieName>WWF9sLID</CookieName> 
   <CookieKey>UID</CookieKey> 
   <CookieData>administrator-Z2DF-5C9-B31B-92ZA</CookieData> 
   <CookiePath>/forum/</CookiePath> 
   <ForumPath>http://127.0.0.1:92/forum/</ForumPath> 
  </Record> 
 </ResultData> 
</ApiResponse>

I am not sure what should I do with this data. When I write a cookie like this:

response.cookies(cookie_name)(cookie_key) = cookie_data
response.cookies(cookie_name).path = cookie_path

I am still not logged in into forum. I want to be able to login user to forum through my login form. Please tell me how.


P.S.
I am also having problem with GetMemberByID method, when I make request I get an error:


<font face="Arial" size=2> 
<p>Microsoft VBScript runtime </font> <font face="Arial" size=2>error '800a000d'</font> 
<p> 
<font face="Arial" size=2>Type mismatch: 'Server.HTMLEncode'</font> 
<p> 
<font face="Arial" size=2>/forum/HttpAPI.asp</font><font face="Arial" size=2>, line 327</font>

I didn't made any changes to forum. Just for the record.



Replies:
Posted By: 123Simples
Date Posted: 17 July 2010 at 6:39pm
If you http://www.webwiz.net/webwizforums/kb/existing_members_api.asp" rel="nofollow - read through this page here it may help you. Personally I've not tried it but Web Wiz Bruce, Scotty32 and many others here are much more inclined to be able to give you a better answer

-------------
http://www.123simples.com/" rel="nofollow - Visit 123 Simples Web Design


Posted By: tjodalv
Date Posted: 17 July 2010 at 6:47pm
Yes I know about that, but for that login method I need user e-mail, but in time of login i don't know user e-mail, so, after calling LoginMemberCookie to authenticate user I need to call GetMemberByID method to retrieve user e-mail, but that method is not working (read my first post, P.S. part)

If i cannot login to forum with LoginMemberCookie method, I don't understand what that method is used for.

Thanks!


Posted By: 123Simples
Date Posted: 18 July 2010 at 6:30pm
Okay tjodalv

Hopefully Bruce can give you the right answer as this bit is above me I'm afraid


-------------
http://www.123simples.com/" rel="nofollow - Visit 123 Simples Web Design


Posted By: WebWiz-Bruce
Date Posted: 19 July 2010 at 1:52pm
The LoginMemberCookiegives you the data you need to create your own cookie so that after the cookie is created the member can browser to the forum without logging in.

The main parts you need to create the cookie are:-

CookieName - This is the Name of the cookie you need to create
CookieKey - This is the key within the cookie that the data is stored under
CookieData - This is the data that you store under the cookie key

The cookie should look like

WWF9sLID
UID=administrator-Z2DF-5C9-B31B-92ZA

You also have additional data such as the cookie path, in case you also want to include that in the cookie.


-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting


Posted By: tjodalv
Date Posted: 19 July 2010 at 4:04pm
Please look at my first, post. After I create cookie and navigate in browser to the forum I am not logged in ...

Also can you tell me why I get an error when I use GetMemberByID or GetMemberByName method. I am interested to buy the forum, but it concerns me that the API, an thoose errors.

Thank you !


Posted By: WebWiz-Bruce
Date Posted: 19 July 2010 at 5:07pm
The only reason why can think the cookie does not work is that you must be creating it wrong. Also you should note that cookies can only be read in by the domain that set the cookie, so you can not set a cookie for another website or sub domain.

Have tested the etMemberByID or GetMemberByName method and can not find any problems with them. It maybe that the member was not created properly in the database or that it is something else wrong with the account you are trying to get.

-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting



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