mirror of
https://github.com/php/php-src.git
synced 2025-01-20 18:53:37 +08:00
40 lines
715 B
Plaintext
40 lines
715 B
Plaintext
|
--TEST--
|
||
|
Test session_start() function : variation
|
||
|
--SKIPIF--
|
||
|
<?php include('skipif.inc'); ?>
|
||
|
--INI--
|
||
|
session.auto_start=1
|
||
|
--FILE--
|
||
|
<?php
|
||
|
|
||
|
ob_start();
|
||
|
|
||
|
/*
|
||
|
* Prototype : bool session_start(void)
|
||
|
* Description : Initialize session data
|
||
|
* Source code : ext/session/session.c
|
||
|
*/
|
||
|
|
||
|
echo "*** Testing session_start() : variation ***\n";
|
||
|
|
||
|
var_dump(session_id());
|
||
|
var_dump(session_start());
|
||
|
var_dump(session_id());
|
||
|
var_dump(session_destroy());
|
||
|
var_dump(session_id());
|
||
|
|
||
|
echo "Done";
|
||
|
ob_end_flush();
|
||
|
?>
|
||
|
--EXPECTF--
|
||
|
*** Testing session_start() : variation ***
|
||
|
string(%d) "%s"
|
||
|
|
||
|
Notice: A session had already been started - ignoring session_start() in %s on line %d
|
||
|
bool(true)
|
||
|
string(%d) "%s"
|
||
|
bool(true)
|
||
|
string(0) ""
|
||
|
Done
|
||
|
|