session file naming
The开发者_StackOverflow中文版 session files are saved at session_save_path().'/sess_'.session_id()
.
Is 'sess_' hard-coded?
If it can be specified, how do I do that?
Yes, sess_
is a hard-coded prefix for the session file name. You can see that in the source file mod_files.c:
#define FILE_PREFIX "sess_"
I think it's hard-coded - at least, I can see no configuration option or parameter to control this.
The manual page for session_save_handler()
provides a full example for a custom handler. If all else fails, you can use that to implement your own handler, and change the naming format there.
Answer found on http://php.net/manual/en/function.session-set-save-handler.php. It's hard-coded.
精彩评论