开发者

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.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜