Re: Connect To Java Servlet using c# windows forms
- From: inpuarg <donteventhink@xxxxxxxx>
- Date: Wed, 14 May 2008 17:37:06 +0300
in java servlet documents i saw such things :
public static string TheSessionId() {
HttpSessionState ss = HttpContext.Current.Session;
HttpContext.Current.Session["test"] = "test";
HttpContext.Current.Response.Write(ss.SessionID);
return "ok";
}
------------
public class MyServlet extends HttpServlet {
public void doGet(HttpServletRequest request, HttpServletResponse
response)
throws ServletException, IOException
{
response.setContentType("text/html");
PrintWriter out = response.getWriter();
HttpSession session = request.getSession(true);
out.println("The session ID: " + session.getId() + "<BR>");
i may need that session id.
how can i get that session id from servlet ?
On Wed, 14 May 2008 06:01:03 -0700 (PDT), "Jon Skeet [C# MVP]"
<skeet@xxxxxxxxx> wrote:
On May 14, 1:19 pm, inpuarg <donteventh...@xxxxxxxx> wrote:.
well. after login if i try to browse a page it says session is invalid
etc. (as a custom message in turkish)
i am capturing https traffic using fiddler. i didn 't see any session
or cookie in both request or response header or detail. there is only
a token string. and i am parsing and sending it also. and i am not
doing anything about session or cookie management.
I strongly suspect it's that token which is controlling the session.
How are you determining the URLs to open? It could well be that
they're autogenerated (in the response links) with the session token
on them.
Jon
- Follow-Ups:
- Re: Connect To Java Servlet using c# windows forms
- From: Jon Skeet [C# MVP]
- Re: Connect To Java Servlet using c# windows forms
- References:
- Connect To Java Servlet using c# windows forms
- From: inpuarg
- Re: Connect To Java Servlet using c# windows forms
- From: Jon Skeet [C# MVP]
- Re: Connect To Java Servlet using c# windows forms
- From: inpuarg
- Re: Connect To Java Servlet using c# windows forms
- From: Jon Skeet [C# MVP]
- Connect To Java Servlet using c# windows forms
- Prev by Date: Re: Calculator control for web application (preferably infragistics)
- Next by Date: Is partial deduction of generic parameters possible
- Previous by thread: Re: Connect To Java Servlet using c# windows forms
- Next by thread: Re: Connect To Java Servlet using c# windows forms
- Index(es):
Relevant Pages
|