I've been asked to develop a social networking site to tie in with a game. The game is in Flash (so delivered as just a .swf
file) and will be hosted on the social networking website.
One of the issues that's arisen during testing and developing is sessions timing out. I know session length can (theoretically) be modified using php.ini
but in this instance it doesn't seem to have worked, most likely due to restrictions by our hosting provider.
Sessions are timing out because the game opens in a pop-up window, and if visitors remain on the game window for a long period of time, close the window and then attempt to use the social networking website, the next page load prompts them to log in.
Therefore, if I dropped a small JavaScript snippet into the head of my pages that simply fires off a request to a file hosted on the website, will that persist a session? If so, are there any drawbacks to this practice?