Session.SessionID, if it uses session state, why put it in the URL?
Hi,I have a website which uses Session.SessionID as a key, to lookup information about the user in my database (essentially managing state from page to page). I'm trying to make my site web-farmable and am having issues. It seems I can no longer user Session.SessionID to identify a user because it uses 'Session State' which is a no go on webfarm. I am aware that if the user has cookies turned on, it's all good, but I want users with cookies turned off to also be able to use my site.What confuses me is when cookies are turned off and a user browses my site, the SessionID appea...
login using session and login using cookies,what is the difference??
login using session and login using cookies,what is the difference??
which is better?
You need to specify if you are using FormsAuthentication (which uses cookies) or some other option. Also, note that Session also uses cookies except when you are using cookieless sessions.Hope this helps,Vivek Social Networking Platform in ASP.NET || Join now: CodeASP.NET Community Please mark the most helpful reply/replies as "Answer".
I agree , maybe showing us your code may help. Login using session sounds quite unclear to me.
/Kadji ...
Using Session State for logins
Howdy,I'm currently making a webpage that will allow a user to login, then edit their own information. The users and their information are defined in a database, and after a user logs in, I want them to stay "logged in" to the site... I'm pretty sure the solution to that is Session State.Before you say to use it, I'm not going to be using the login control, and am instead using just some textboxes and a button within a form (I'm doing it this way for simplicity's sake).With that, my question is simply this: How can I transfer the username/password information from the initi...
Login script using @NET USE for login name
--____SJDNMAUHJRPPCUAIVNQS____
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: base64
Content-Disposition: inline; modification-date="Thu, 27 Aug 2008 11:50:31
-0400"
Q3VycmVudGx5IHVzaW5nIHRoZSBmb2xsb3dpbmcgdG8gbWFwIGEgaG9tZSBkaXJlY3Rvcnkgb24g
YSBNQUMgT1NYIHNlcnZlciBmb3IgdXNlcnMgbG9nZ2luZyBpbnRvIGEgTmV0d2FyZSA2LjUgc2Vy
dmVyLg0KDQpJRiBMT0dJTl9OQU1FPCJFIiBUSEVODQogICBATkVUIFVTRSBIOiBcXFNKUFMtT1NY
MVxIT01FX0RJUkVDVE9SSUVTXFRFQUNIRVJTQS1EXCVMT0dJTl9OQU1FICAvUEVSU0lTVEVOVDpO
Tw0KICAgV1JJVEUgIk1BUFBJTkcgVE8gT1NYMSINCkVORA0KDQpUaGlzIHdvcmtzIGZvciB1c2Vy
cyB3...
how to use state server to manage sessions
How does one use the state server?
Can anyone explain the process how the state server is used or give me some links to which I can refer to, which will explain the same?
Basically, we have a web farm environment and we need to persist data across the web farm, for which we intend to use the state server
Hi,
on the server where State Server will be running, on Services just start the "ASP.NET State Service" service. Then on web.config <sessionState> element in web apps change the mode attribute to "StateServer" and check that stateConnectionString attri...
Using session state for login details
I'm not sure the best way of setting up a site with login/password but I've been told to do it like this. Each page checks if the user is valid. So I'm thinking of having a namespace that includes code to redirect to the login page. Then I need to setup session state to check on each page the user. How is this done? Should I use a class for each page or namespace?
hi
it is better to have another class and implemt this class in your all pages , and common code wirte it in this class
Public Class Sample : System.Web.UI.Page
{
//your coomon code for checking user or any thing
...
Using UpdatePanel vs manually using sys.net.webrequest for WebRequests
Hi Experts,
I'm aware that the UpdatePanel control uses the Sys.Net.WebRequest class internally for asyncronous calls to the server.But i want to know which is the best approach for getting data from server to the client.1) Using an UpdatePanel control and using Server side ASP.NET controls within the UpdatePanel control (or)2) Using HTML controls and using the methods of the Sys.Net.WebRequest class to gather or Post data.I realize that the UpdatePanel comes with a lot of glue code that makes the magic of AJAX happen.Does usin...
Session state management using web services.
Hi all ,i am working of a hospital management system which we desided to develop using atlas frame work. we have created the application main to sections using atlas script call back architecture. we are using scripts to pack the user entered data to the web service and in that web service we are entering the data in to the database.all this happening with out a post back of the page.now comes the problem. we are not being able to handle the user session properties. we came to know that we cant access session variables in web services. we are in a trap now. how we can manage the sessio...
Unable to use session state server....requires session state server version 2.0 or above.
So, I have Windows 2003 IIS latest service packs running. Its running .NET 2.0 and .NET 1.1 applications in seperate application pools.
Just today I applied the following patch to the server. (The server is not running any 3.0 or 3.5 applications or application pools)
Microsoft .NET Framework 3.5 Service Pack 1 and .NET Framework 3.5 Family Update (KB951847) x86 Microsoft .NET Framework 3.5 Service Pack 1 is a full cumulative update that contains many new features building incrementally upon .NET Framework 2.0, 3.0, 3.5, and includes cumulative servicing upda...
how to get Session from Login control and use it to query on the Gridview.
As shown above..
Hi
Base on my understanding, you want to store user information in session variable and retrieve it to query in gridview.
------------after login---------
Session["uname"] =Login1.UserName;
--------------retrieve the session------------
<asp:SqlDataSource ID="DataSource1" runat="server" ConnectionString=" "
ProviderName="System.Data.SqlClient" SelectCommand="SELECT * FROM tables WHERE WHERE UserId = @UserId ">
</asp:SqlDataSource> <...
Using Sessions in Login page and to maintain state through out application.
Hello members,
I am new to .net and this is my first post. I have made a login page for a small website whihc I am making. I am doing the website in C#.net. Sqlserver 2005. I am getting confused about how to use sessions in login page and how to maintain the state in all other pages of my website.
Please help me with some sample code.. that would be greatly appreciated. I got struck basically in how to carry the username and password to all the pages to maintain state.
Please help me out by givnig some sample code. My login page has this code,
protected void Button1_Click(object ...
automatically login to another site using Session variable from my site
Once a user logs into their account, I want them to be able to click a button that will redirect them to another site's login page, and automatically log them in. I have the users login info for the other site on their user account page, but the label controls aren't visible.
I know there is a way to do this with PHP, using <form action="https://page.com/login.aspx" method="post" name="login"> with a simple submit button. Can I do this with ASP.NET?
Here is what I have so far:Partial Class loginInherits System.Web.UI.PageProtected Sub Page_Load(ByV...
Navigating to a Login page and back again using Session state for control
I'm trying to do something that should be simple, but I am stymied.
My default page has a "Please Sign In" LinkButton which has PostBackUrl set to "~/SignInPage.aspx". When default page loads it examines Page.Session.Item("usrlogin") and, if it is "nothing" it executes:
Page.Session.Item("usrlogin") = "x" thereby hopefully establishing a session variable that I can use to communicate between pages.
When the user clicks the LinkButton on default page, the signin page loads. On signin&nbs...
Good news for those of you who get "Unable to make the session state request to the session state server." error..
Dear all,Due to the known problem of session variables getting lost if using InProc-server during frequent changes in development, I had to choose between SQL and ASP.NET State server, so I opted for the second. Initially, all fine, but after using it for a few days, I started to get this error: Server Error in '/cv2' Application.Unable to make the session state request to the session state server. Please ensure that the ASP.NET State service is started and that the client and server ports are the same. If the server is on a remote machine, please ensure that it accep...