rfc:session-oo
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | Next revisionBoth sides next revision | ||
rfc:session-oo [2011/06/03 00:51] – specify php in code block arpad | rfc:session-oo [2011/06/03 01:00] – slightly more useful example arpad | ||
---|---|---|---|
Line 25: | Line 25: | ||
<?php | <?php | ||
class MySession extends SessionHandler { | class MySession extends SessionHandler { | ||
- | public static function open($path, $name) { | ||
- | echo 'Open ', session_id(), | ||
- | return parent:: | ||
- | } | ||
public static function read($key) { | public static function read($key) { | ||
- | echo 'Read ', session_id(), " | + | return str_rot13(parent:: |
- | return parent::read($key); | + | } |
+ | |||
+ | public static function write($key, $data) { | ||
+ | return parent::write($key, str_rot13($data)); | ||
} | } | ||
} | } |
rfc/session-oo.txt · Last modified: 2017/09/22 13:28 by 127.0.0.1