Forum Moderators: coopster

Message Too Old, No Replies

Session values is not maintained in all the pages using I-mode HTML si

         

venki

8:45 am on Aug 29, 2009 (gmt 0)

10+ Year Member



Hi
I am developing Amazon web service API.I am developing this in mobile . Session maintenance is an important for this project.I can't maintain session values page by page.If i brows in IE it is working properly but when i test in I-mode HTML simulator it is not working.
So i maintained the session values in the following manner
PHP Code:

<?php
ini_set("session.use_trans_sid",1);
session_start();
?>

But the session values are passed in the URL.The session id is visible to the user .I think it is not good idea and i dont like to get the values from cookies also .How can i maintain the session using store and retrieving from the file (ie,session.save_path = "c:/wamp/tmp"). This method is working fine in IE and other browser but it is not working in I-mode HTML simulator II.Here is the code i tested

<?php
session_start();
?>

But every time new session id is generated only in simulator but working fine in all other browser

jdMorgan

2:13 pm on Aug 29, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Although we use the word "sessions" for convenience, what we're doing is tracking the "user state." That can be done client-side by using cookies, or it can be done server-side by putting the "user state" in the URL.

These are the two ways to accomplish it, and there's no 'magic' involved; It's either a cookie or a query parameter -- data that is sent by the client to your server with each request.

As such, it sounds like the I-mode simulator does not support cookies, and so your "sessions" don't work.

Best practices indicate that your site should provide for clients that don't support cookies (or where the user has disabled them). So if the client supports cookies, use the cookies-based session method. If not, then use the query-string-on-URL method.

Jim