Re: Dynamic Array Q
| From: | Chris Allen | Date: | Fri, 28 Dec 2001 22:41:57 +0000 |
| Subject: | Re: Dynamic Array Q | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-78979@lists.php.net to get a copy of this message | ||
never mind...gheez my head is holidazed :)
$Schedule = array();
while ($row = mysql_fetch_object($result_query))
{
$look = "$row->year" . "$row->month" .
"$row->day";
$title = $row->title;
$Schedule[$look] =$title;
}
Happy New Year!!
-ccma
----- Original Message -----
From: "Chris Allen" <callen@driver8.org>
To: <php-general@lists.php.net>
Sent: Friday, December 28, 2001 4:27 PM
Subject: [PHP] Dynamic Array Q
> Hey!
>
> Looking for a way to add an entry in my array ...the way I have it the
array
> is getting rebuilt everytime...
> Anyway to add an entry without calling a function to do it inside the main
> while loop??
>
> while ($row = mysql_fetch_object($result_query))
> {
> $look = "$row->year" . "$row->month" .
> "$row->day";
> $title = $row->title;
>
>
> $Schedule = array(
> $look => "$title",
> );
>
> }
>
>
> thanks,
>
> ccma
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>
>