ehdesign Posted August 24, 2007 Share Posted August 24, 2007 Can I do this - $_SESSION['this'][$x] - I need to have mutiple dimensional $_SESSION array???? Any help / thoughts? Link to comment https://forums.phpfreaks.com/topic/66429-solved-multiple-dimension-session-array/ Share on other sites More sharing options...
hitman6003 Posted August 24, 2007 Share Posted August 24, 2007 Can I do this - Have you tried it? Link to comment https://forums.phpfreaks.com/topic/66429-solved-multiple-dimension-session-array/#findComment-332528 Share on other sites More sharing options...
trq Posted August 24, 2007 Share Posted August 24, 2007 Have you tried? The $_SESSION array is no different to any other array besides the fact that it has some persistence. Link to comment https://forums.phpfreaks.com/topic/66429-solved-multiple-dimension-session-array/#findComment-332529 Share on other sites More sharing options...
MadTechie Posted August 24, 2007 Share Posted August 24, 2007 i think you should try it.. start with $_SESSION['test'] = "hello"; then $_SESSION['test']['test2'] = "hello"; remember print_r($_SESSION); helps Link to comment https://forums.phpfreaks.com/topic/66429-solved-multiple-dimension-session-array/#findComment-332530 Share on other sites More sharing options...
teng84 Posted August 24, 2007 Share Posted August 24, 2007 if this thing work then i should say its better $array=array(value here); $_SESSION['cc']=$array; Link to comment https://forums.phpfreaks.com/topic/66429-solved-multiple-dimension-session-array/#findComment-332534 Share on other sites More sharing options...
clearstatcache Posted August 24, 2007 Share Posted August 24, 2007 i olwez prefer having a multiple dimension array nd then assigning this array to $_SESSION var... say.... $array['test'][0] = 0; $array['test'][1] = 1; $array['test1'][0] = 10; $array['test'][1] = 11; $_SESSION['array'] = $array; Link to comment https://forums.phpfreaks.com/topic/66429-solved-multiple-dimension-session-array/#findComment-332644 Share on other sites More sharing options...
ehdesign Posted August 24, 2007 Author Share Posted August 24, 2007 I had tried it and was seeing problems. But I think I found the issue aside from this. So, the problem is solved. Thanks. I like the idea of putting the info into a standard array and then throwing that whole array into the session array... I'll mark this as solved. Great job. Link to comment https://forums.phpfreaks.com/topic/66429-solved-multiple-dimension-session-array/#findComment-332916 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.