Scriptcase supposedly supports storing sessions in database. When the page request comes in, the server gets the session variables from the common database instead of its own session file. This problem is generally solved by enabling the storing of sessions in a database that both servers share. If you get connected to Server A on your first page request, and then Server B on your next request, the variables would all change. Server A and Server B would be keeping a different set of session variables for a particular browser. Although very powerful, this approach is fraught with perils and requires in-depth knowledge of browser/server interaction and a well planned and executed design.Īnother side effect of the way sessions work:īesides the obvious problem of multiple tabs sharing the same session, another problem of current browser/session design occurs if you have multiple servers in a cluster in order to support load balancing or high availability. Scriptcase will supposedly support passing session IDs in the URL if you enable this option. Instead of having the server retrieve a cookie to get the session ID from the browser, the session ID can be passed in the URL. If you configure multiple aliases for an HTTP server, like “ ” and “ ” then they will have different PHPSESSID cookies and so they will have different sessions, if they are each open in a different tab in the same browser, even though it is actually the same server serving the same pages. You can have multiple URLs for the same server. These windows do not share cookies with each other, consequently the server treats the requests as though they are coming from different PCs: each has a different session. Most browsers have a way to open a window that has a separate session - in Firefox it is called a “Private Window”, in Chrome it is called an “Incognito Window”, etc. It has been that way since tabs first appeared in browsers. As a consequence of this, all tabs that reference the same server URL share the same session. For instance, “ ” and “ ” can each have a different PHPSESSID cookie, so each has a different session number to use when they communicate with their respective servers.Īll tabs in a browser that reference the same server URL share the same cookies. Cookies are referenced not only by their name, but also by which URL they are attached to. When a browser requests information from a server that is running php, it uses a cookie (usually called PHPSESSID) to tell the server’s php which session to use. If I open the same generated application in two different tab in the browser, the parameter passed to one tab is received also from the application in the other tab…Ī Session is simply a group of variables (in our case, php global variables) on a particular server used to store application state information.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |