Jump to content


Photo

session array problem


  • Please log in to reply
1 reply to this topic

#1 Birdman203

Birdman203
  • Members
  • PipPip
  • Member
  • 24 posts

Posted 12 August 2006 - 03:39 AM

$count_session = count($_SESSION['topics']);
$id = $_GET['id'];
$array_session = array(
	'id' => $id
);
$array_session2[$count_session] = $array_session;
$set_session = $_SESSION['topics'][$array_session2];

how come this doesnt work? or am i doin somethin wrong?

#2 hostfreak

hostfreak
  • Members
  • PipPipPip
  • Advanced Member
  • 581 posts

Posted 12 August 2006 - 03:55 AM

Try:
$count_session = count($_SESSION['topics']);
$id = $_GET['id'];
$array_session = array(
	'id' => '$id'
);
$array_session = $array_session2[$count_session];
$set_session = $_SESSION['topics'][$array_session2];





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users