Assoiative Array and Accessing Them

From: Date: Sun, 18 May 2003 01:32:03 +0000
Subject: Assoiative Array and Accessing Them
Groups: php.general 
Request: Send a blank email to php-general+get-148064@lists.php.net to get a copy of this message
Hi, I'm trying to do one job here. Please take look at a simple foreach loop below first. foreach($result_p as $key => $value) { $result[] = $result_p[$key]; } And I need to modify one of value that is in $result_p[$key]. Let's say that is called $result_p[date]. By the way I'm still beginner and I was trying to change value and put it to $result[] array. $result_p[date] is unix time stamp. And I'm trying to change those time stamp to mm/dd/YYYY format by using mktime(); Something like... foreach($result_p as $key => $value) { $result_p[$key][date] = date ("m/d/Y", $result_p[$key][date]); $result[] = $result_p[$key]; } I know this is not working at all, and I really need to find out how. Please someone help. Ken

« previous php.general (#148064) next »