# create links in AS3 with PHP

**URL:** https://forum.kirupa.com/t/create-links-in-as3-with-php/634139
**Category:** flash
**Created:** [January 12, 2016, 9:16pm UTC](https://forum.kirupa.com/t/create-links-in-as3-with-php/634139 "2016-01-12T21:16:53Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Stephan\_Berger](https://avatars.discourse-cdn.com/v4/letter/s/3bc359/32.png) [@Stephan\_Berger](https://forum.kirupa.com/u/Stephan_Berger)
#### Post date: [January 12, 2016, 9:16pm UTC](https://forum.kirupa.com/t/create-links-in-as3-with-php/634139/1 "2016-01-12T21:16:53Z")

</div>

I’ve got this code that retrieve data from my SQL Data Base into my AS3 code.

My table (data base) has this rows : “id”, “title”, “price”, “information”, “mail”.

In my AS3 code I loaded “title”.

Php Code :

> while ($row = mysql\_fetch\_array($sql\_result)) {  
> $theTitle = $row["theTitle "];  
> $phptheTitle= $phptheTitle.’   
> '.$theTitle ;  
> }  
> echo “phptheTitle=” . $phptheTitle;

AS3 code :

> var myResult:String = evt.target.data.phptheTitle;  
> output\_txt.htmlText = myResult;

So my output\_txt is displaying all items in the row “title”.

Now, is it possible to create a link for each title(in AS3) ? In order to display “price”, “information”, “mail” when we click on the title(each title has their own “price”, “information” and “mail”, contain in my database).

Exemple : The AS3 code displays “Computer”. When I click on “ipod Touch” it displays “price”, “information” and “mail” that is contains in my database.

Here’s a video explaining what I’d like to do : [help2 - Sendvid](https://sendvid.com/whdm4sjf)

Thx
