Retrieving several rows from a database (PHP)

I have a database in MySQL and I have PHP. I can write a script in PHP that retrieves several rows from a database (like when I search in a Title column to ‘Red Knight’).

How do you show the results (several rows with several information like the ISBN and the author of the book) in flash???

(When I click on the name of the right book I want to look at in detail, I want to go to a detail page(this is not so difficult), but there must be a link(so ID should be stored))

Do you have to create several dynamic TEXTfields to give the user a ‘table’ of results???

Thanks

Nico

This tutorial shows you how to send and recieve information from Flash:

http://www.kirupaforum.com/forums/showthread.php?s=&threadid=17604

use the same priniciple, just subsistute the flat file for the database…

this could help too: http://www.kirupa.com/developer/actionscript/flash_php_mysql.htm

Yep, thank you,

I know how I can do that, but my real problem is this:

What is the best manner to receive multiple rows from a database and then setting them in a TABLE like look.

(see also first post)

Thanks

Nico

oh for that you would have to set up your textboxes to look like a table. There is no way to pull a table into Flash…

So I have to work with several DYNAMICALLY created textboxes??

is that right??

they dont’ need to be dynamically create, but that would be the best way to go

Depends if you have the same n° of txtboxes for each book, if so, just add them to layout, if no, maybe better with “createTextfield” or whatever the exact syntax was…
as for sending multiple rows to flash, id use loadVars so you get all the result into one object, and a loop in php to add a counter var to the output (book1ID=x&book1ISBN=xx&book2ID=…);
for the display in flash you could also use macromedias datagrid component ( http://www.macromedia.com/software/drk/productinfo/product_overview/volume1/flash_components.html ) or a free version called something like tkcDatagrid, http://www.flashcomponents.net/component.cfm?nav=2&id=135