|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2007-04-04 19:02 UTC] jason dot polaris at gmail dot com
Description: ------------ Currently I am trying to store a lot of data in the session (i.e. filename and things related to that particular file) However some filename(with full path) can be more than 300 characters, and it is not stored if I use the path as a $_SESSION key. Any key that contains less than 250 characters surely works well. Reproduce code: --------------- <?php session_start(); $_SESSION['asdklfjsldfkjsldkfj(more than 300 chars)']['ABC'] = 1; ?> Expected result: ---------------- When reloading (or redirect to another page that reads session) $_SESSION['asdklfjsldfkjsldkfj(more than 300 chars)']['ABC'] will equals to 1 Actual result: -------------- The session array ($_SESSION['asdklfjsldfkjsldkfj(more than 300 chars)']['ABC']) is simply not set PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 11:00:01 2025 UTC |
Currently I am using my XP machine, so I just put it in: C:\PHP\sessiondata When I look inside the sessiondata folder, there is serveral files. I use my text editor to search for my target "key", I found: L_CHR058_CHR047AutoPlayv2_CHR047Autoplay_CHR032in_CHR032Windows_CH|a:1:{s:3:"P3R";s:1:"1";} which is part of a key that I had set. However, there is even more character goes beyond Windows_CH............. For others, e.g. L_CHR058_CHR047htdocs_CHR047stage2_CHR047drivesel_slice_CHR047Untitled_CHR0451_24_CHR046gif|a:1:{s:3:"P3R";s:1:"1";} The actual statement I have used: $_SESSION['L_CHR058_CHR047AutoPlayv2_CHR047Autoplay_CHR032in_CHR032Windows_CHR032XP_CHR032_CHR032Automatically_CHR032Detect_CHR032and_CHR032React_CHR032to_CHR032New_CHR032Devices_CHR032on_CHR032a_CHR032System_CHR032_CHR045_CHR045_CHR032MSDN_CHR032Magazine_CHR044_CHR032November_CHR0322001_files_CHR047t_CHR046gif']['P3R'] = 1; (I know, a little bit long...)