- substr: documentation ( source)
- ob_start: documentation ( source)
- ob_get_contents: documentation ( source)
- ob_end_clean: documentation ( source)
- session_set_save_handler: documentation ( source)
- session_start: documentation ( source)
<?php
session_set_save_handler(
function() {return true;},
function() {return true;},
function() {return true;},
function() {return true;},
function() { $contents = ob_get_contents(); ob_end_clean(); print substr($contents, 0, 5); print ' PHP '; print substr($contents, 5); return true; },
function(){return true;}
);
session_start();
ob_start();
echo 'Hello';
echo 'World';