PHP - Sessions and CookiesWhich of the following is TRUE about PHP session IDs?ASession IDs must be manually created by the programmerBSession IDs are stored in cookies by defaultCSession IDs are encrypted automaticallyDSession IDs are visible in the URL by defaultCheck Answer
Step-by-Step SolutionSolution:Step 1: Understand default session ID storagePHP stores session IDs in cookies by default to track sessions.Step 2: Check other optionsSession IDs are not visible in URL by default, not encrypted automatically, and not manually created.Final Answer:Session IDs are stored in cookies by default -> Option BQuick Check:Default session ID storage = cookies [OK]Quick Trick: Session IDs use cookies unless configured otherwise [OK]Common Mistakes:Thinking session IDs appear in URLs by defaultBelieving PHP encrypts session IDs automaticallyTrying to create session IDs manually
Master "Sessions and Cookies" in PHP9 interactive learning modes - each teaches the same concept differentlyLearnWhyDeepVisualTryChallengeProjectRecallTime
More PHP Quizzes Classes and Objects - Destructor method - Quiz 3easy Error and Exception Handling - Finally block behavior - Quiz 11easy Error and Exception Handling - Try-catch execution flow - Quiz 7medium Inheritance and Polymorphism - Constructor inheritance - Quiz 2easy Interfaces and Traits - Trait conflict resolution - Quiz 1easy Interfaces and Traits - Why interfaces are needed - Quiz 3easy Sessions and Cookies - Session variables - Quiz 2easy String Functions - Trim functions - Quiz 14medium String Functions - String search functions (strpos, strstr) - Quiz 3easy Superglobals and Web Context - $_FILES for file uploads - Quiz 2easy