1--TEST-- 2Test session_reset() function : basic functionality 3--SKIPIF-- 4<?php include('skipif.inc'); ?> 5--INI-- 6session.save_path= 7session.name=PHPSESSID 8session.save_handler=files 9--FILE-- 10<?php 11 12ob_start(); 13 14echo "*** Testing session_abort() : basic functionality ***\n"; 15 16session_start(); 17$session_id = session_id(); 18$_SESSION['foo'] = 123; 19session_commit(); 20 21session_id($session_id); 22session_start(); 23$_SESSION['bar'] = 456; 24var_dump($_SESSION); 25session_reset(); 26 27var_dump($_SESSION); // Should only have 'foo' 28 29echo "Done".PHP_EOL; 30 31?> 32--EXPECT-- 33*** Testing session_abort() : basic functionality *** 34array(2) { 35 ["foo"]=> 36 int(123) 37 ["bar"]=> 38 int(456) 39} 40array(1) { 41 ["foo"]=> 42 int(123) 43} 44Done 45