session

Saving session data with Javascript, or similar solution

Basically what I'm trying to achieve is a basic back capability. User goes into Girls listing, which shows him a location screen. Selects a location, and the locations are replaced by images of girls from that location using AJAX. User clicks on a particular girl to view her profile. Now the user wants to go back and have a look at a dif...

Monitoring User Sessions to Prevent Editing Conflict

I'm working on something similar to a pastebin (yeah, it's that generic) but allowing for multiple user editing. The obvious problem is that of multiple users attempting to edit the same file. I'm thinking along the lines of locking down the file when one user is working on it (it's not the best solution, but I don't need anything too co...

How to set up a secure PHP Session

In a similar vein to my previous question - I'm not a very experienced PHP Programmer. I know nothing about Sessions or Security (other that what I learnt an hour ago about md5 and sha1 with salt). I have a login system, and I wish to create a session that stores and encrypted string of a user's username mixed with a timestamp. I know ...

Dump session to DB when restarting web server?

How would one go about making sure the InProc session memory gets stored in a DB so it's possible to restart the web-server without losing sessions? ...

Header redirect, sessions lost, but only after about 5 minutes

function redirect($url){ header("HTTP/1.1 303 See Other"); header("Location: $url"); exit(); } I have the function called when certain input buttons are clicked. The session is set on every page, and it IS passed if the the button is clicked within 5 minutes. But the session is lost after about 5 minutes if the button is ...

Keeping track of users with PHP session id, cookie + database

I'm having a small bit of doubts here as to how sessions should be handled. Right now, I have a MySQL database where the "users" table has a field for session_id. If NULL, the user is not logged in? If the value is the same as the value of the PHPSESSID cookie, than the user is logged in. I don't know why, but I somehow feel this isn't...

how to automate multi user login for browser scenarios

Hi, Currently when i try to login with mutli users only one login is allowed in the browser. my requirement is to be able to login with multi logins. I'm using IE if it helps. you response will be very appreciated. ...

Is setlocale restricted to its script instance?

According to PHP, "locale information is maintained per process." Is my understanding correct that this is the same as saying per script instance with an Apache server? In other words, if I have several concurrent sessions using different locales, can changes in one user's locale settings interfere with another's? Also is there a conve...

Session Key & Access Token in Facebook-API

Can someone please explain to me once and for good what are Session Key & Access Token? How do I catch those two? Why and when do I need them? When is it one-time and when is it not? Also, what are the differences between them either the application already installed or not. Please do it in Java. I'm a new-to-facebook-api Java developer...

Check the existence of a session (Nginx)

Hi guys. I have two sessions in PHP: $_SESSION["session"]["key"] = md5 ($token . $userAgent . $ip); $_SESSION["session"]["timeout"] = time (); Just want to check that sessions with nginx, tried this code without success: location / { if ($request_filename ~* "index.php") { break; } if ($http_cookie ~* "session")...

Inherit session even if opening a new instance of IE7

I understand that sessions are kept when opened in a new tab but is it possible to inherit the session when opening a new instance of IE7 or IE6? For example, I opened a web application, if I opened a new browser and I went to the same URL, it will keep me logged in. ...

Classic asp persist custom classes in session

Is it possible to persist a class in session that I define in VBScript in classic asp: <script runat=server language=vbscript> Class clsCourse Private Sub Class_Initialize ' Statements go here. End Sub End Class dim oCourse set oCourse=new clsCourse </script> How would I persist oCourse in session and recover it from session? I ...

What happens if I don't call session_start() ?

I'm trying to make many of the pages in my site cache-able as HTML. As a result, I won't be able to call session_start() on those pages. Do sessions work if you don't call them on every single page? ...

PHP: Removing items from a session

I'm having trouble removing items in a session array in a shopping cart project. The following code should take the selected item and remove it from the session. However the end result is just the same session as before with nothing removed. I've seen similar problems by googling, but haven't found a working solution yet. Here is the str...

EJB3.0: Using dependency injection as opposed to the session object

Hello there! We're learning EJB 3.0 in school and we're trying to determine best practice for a problem our teacher has posed. We don't use Spring yet. The problem is as follows: Create an EJB that keeps track of the time the bean was last called by the same user (call the first user John) and displays this in a web (servlet) context. I...

Is it possible to use .NET session in IPhone native app?

Hi all, I'm writing a .NET(3.5) web service for an IPhone native app in which I need to manage users' sessions. Question is - can I just add the [WebMethod (EnableSession = true)] attribute to my web services, and the native app (which I'm not the one who's writing and hence the ignorance) would be able to use, or should I write an impl...

How to access to the 'Session' of an EJB?

Dear members, How to get the session object of an EJB session-bean like session object in JSP(web layer)? Because I want to add an attribute to the session and use it later in its process. Regards ...

Session problems when APC is turned on

We have a problem with PHP session when APC is enabled on our server. The app works great without APC. However, since we enabled APC, the sessions seems to be getting mixed up when the server experiences heavy load, i.e. users are randomly logging on as another. Everything reverts back to normal once we disabled APC. We can't seem to fi...

PHP: MYSQL-based session sharing on different machine

Hi all, I have an app sits on machine A (solaris.example.com) and same apps sits on machine B (rhodes.example.com), these two machines are connected to same MYSQL database which has session table on it. I've implemented my own session handler so it saves to the database instead of saving it to the files and this works fine. My questio...

PHP - Inspecting session max lifetime within the code

How do you inspect the value assigned to session.gc_maxlifetime? Obviousely this does not work: echo session.gc_maxlifetime; ...