Re: [PHP] help with multidimentional arrays

2006-04-12 Thread John Wells
On 4/11/06, Bing Du [EMAIL PROTECTED] wrote: == foreach ($sponsor_id as $sponsor = $arr) echo $sponsor:; foreach ($arr[$sponsor] as $project) { echo $projectbr; } == It looks like you're building your array just fine. Here though, your

Re: [PHP] help with multidimentional arrays

2006-04-12 Thread Bing Du
On 4/11/06, Bing Du [EMAIL PROTECTED] wrote: = foreach ($sponsor_id as $sponsor = $arr) echo $sponsor:; foreach ($arr[$sponsor] as $project) { echo $projectbr; } = It looks like you're building your array just fine. Here though, your

[PHP] help with multidimentional arrays

2006-04-11 Thread Bing Du
Hello, What I intend to do is put the database query results in a multidimentional array like this. $sponsor_id['sponsor1'] = ('project1 title', 'project2 title', 'project3 title'); $sponsor_id['sponsor2'] = ('project1 title','project7 title'); Here is the code snippet for doing that: ==

Re: [PHP] help with multidimentional arrays

2006-04-11 Thread Richard Lynch
On Tue, April 11, 2006 1:58 pm, Bing Du wrote: What I intend to do is put the database query results in a multidimentional array like this. $sponsor_id['sponsor1'] = ('project1 title', 'project2 title', 'project3 title'); $sponsor_id['sponsor2'] = ('project1 title','project7 title');