How session works (internal processing of session) ?
Answers were Sorted based on User's Feedback
To start a session:
– session_start()
– Creates a session identifier
– Session identifier is passed between client and server
either as
a Cookie, or in GET parameters
• Then, can create, access, and modify session variables:
– $_SESSION[session_var_name] = value;
– $_SESSION is only available once you call session_start()
– $local_variable = $_SESSION[session_var_name];
– Can check if session variable is set by using isset();
• To end a session:
– session_destroy();
| Is This Answer Correct ? | 9 Yes | 1 No |
Answer / vaibhav jain
server knows this info by the session ID that is generated.
All the values are under a session ID, which is unique.
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / binoyav
I need the answer in more depth.
For ex:- There are two users A & B.
User 'A' is using the machine 'comp_A' and user 'B' is using
'Comp_B'. How the php server knows that user 'A' is using
Comp_A and B is using Comp_B ?
| Is This Answer Correct ? | 2 Yes | 4 No |
What are the popular content management systems (cms) in php?
In how many ways we can retrieve the data in the result set of mysql using php?
Explain the purpose of output buffering in php.
What is the purpose of the following files having extensions: frm, myd, and myi? What these files contain?
What are majic methords in php?
How do sessions work in php?
Can php variables have numbers?
difference between clanguage and c++
How can we submit a form without a submit button? What is the use of obj_star?
2 Answers Rushmore Consultancy,
What is difference between readonly and constant?
How to call a php function from another php file?
Explain the visibility of the property or method?