Which is the correct way to check if a session has already been started ?
Answer / Siddharth Chaudhary
"You can check if a session has already been started in PHP by using session_id() function. If session_id() returns a value, it means the session has already been started. Otherwise, you need to start it with session_start()."
| Is This Answer Correct ? | 0 Yes | 0 No |
Explain how we can get the number of elements in an array?
How to use the COM components in PHP?
Write a php script to get the largest key in an array?
What is super keyword in c++?
How can we upload a file in php?
How to remove a file?
Which function would you use to read a line of data from a file in php?
What is session management php?
How to get seconds from current date using date function ?
8 Answers Sarna Technologies, Satyam,
How many different types of messages available in php?
What are the differences between PHP 3 and PHP 4 and PHP 5?
What is the difference between ereg_replace() and eregi_replace()?