# GET id with AMFPHP

**URL:** <https://forum.kirupa.com/t/get-id-with-amfphp/274400>\
**Category:** flash\
**Created:** [October 29, 2008, 3:06pm UTC](https://forum.kirupa.com/t/get-id-with-amfphp/274400 "2008-10-29T15:06:00Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jarah](https://avatars.discourse-cdn.com/v4/letter/j/45deac/32.png) [@jarah](https://forum.kirupa.com/u/jarah)\
**Post date:** [October 29, 2008, 3:06pm UTC](https://forum.kirupa.com/t/get-id-with-amfphp/274400/1 "2008-10-29T15:06:00Z")

</div>

Hi there,

I have a newssystem. My newssytem will read newsarticles from my MySQL database with AMFPHP.

Now i get 6 newsarticles on my screen. But what if i want to retrieve on single newsarticle and that will be viewed in an other frame.

This is my current AS script:

```auto

function onResultaat(responds:Object):void {
    var t:Array = responds.serverInfo.initialData;

    for (var i:uint = 0; i < 5; i++) {
        var o:Newsitem = new Newsitem();
        var maxTekens:Number = 100;
        var tekst:String = t*[4];
        var deelTekst:String = tekst.substr(0,tekst.indexOf(' ',maxTekens));

        o.x = -280;
        o.y = -145 + (70 * i);
        o.tekst.wordWrap = true;
        o.datum.text = t*[1];
        o.buttonMode = true;

        o.titel.htmlText = "<b><a href='?id="+t*[0]+"'>"+t*[2]+"</a></b>";

        o.tekst.htmlText = deelTekst;
        
        o.titel.addEventListener(MouseEvent.CLICK, onClickTitel);
        

        function onClickTitel(e:MouseEvent):void {
            //Get the ID of a single newsarticle
        }

}

```

If i click on a title then i should referer it to an other frame.

I have searched a lot a few days with URLLoader URLVariables sendAndLoad but i can’t get it. This someone know something for these things?

Many thanks!
