# MySQL -\> PHP -\> Flash

**URL:** <https://forum.kirupa.com/t/mysql-php-flash/201080>\
**Category:** flash\
**Created:** [September 18, 2006, 11:46am UTC](https://forum.kirupa.com/t/mysql-php-flash/201080 "2006-09-18T11:46:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Qbe](https://avatars.discourse-cdn.com/v4/letter/q/45deac/32.png) [@Qbe](https://forum.kirupa.com/u/Qbe)\
**Post date:** [September 18, 2006, 11:46am UTC](https://forum.kirupa.com/t/mysql-php-flash/201080/1 "2006-09-18T11:46:37Z")

</div>

Hi

I am trying to move information from a database to Flash via PHP.

I Have the connection between the db and PHP and Flash.  
The problem is that I only can print the last item in my list.

So I made an array.

This is my code:  
\<?php  
////////////// SKICKA INFO TILL FLASH [\\\\\\\](http://www.kirupa.com/forum/)  
$by;  
$con = mysql\_connect(“localhost”, “root”, “”);  
mysql\_select\_db(“gasstat”, $con);  
$res = mysql\_query(“SELECT \* FROM prodkategory”);  
$arr = array();  
$i = 0;  
while($row = mysql\_fetch\_object($res))  
{  
$by=$row -\> ProductCategory;

$arr[$i] = “&toFlash=” . $by;  
$i++;

}  
print("&lenght=$i");

print("&toFlash=$arr");  
?\>

The problem is this row: print("&toFlash=$arr");

I belive I need to assign the objects in the array, but here I assign the arrayobject.

What I get in my list when I test the movie is “Array” five times.

Someone who knows how I can do?

Cheers
