Loading XML after onClipEvent

Hi there,

I’m trying to load XML data after an hitTest but doesn’t work the way I’m programming. Here is the source code:[INDENT][COLOR=Gray]onClipEvent (enterFrame) {

if (_root.ster1_mc.hitTest(_root.rocket)) {
    trace("raak");
    
        function loadXML(loaded) {
            
                _root.Teksten = this.firstChild.childNodes[0].childNodes[0];
                _root.tekst_vlak.text = _root.Teksten;
                
        }
        xmlData = new XML();
        xmlData.ignoreWhite = true;
        xmlData.onLoad = loadXML;
        xmlData.load("http://localhost:8888/test.php");

    
} else {
    _root.ster1_mc.gotoAndStop(1);
    _root.myHeader = "";
    _root.myText = "";
    _root.logo._alpha = 100;    
    _root.tekst = "Drag me to the stars to find out more";
}

}
[/COLOR][/INDENT]When I use the XML code simple on a button it works perfect but after my hitTest it’s doing nothing… :x
When I remove the function it say’s undivined in the textarea.

Can someone please help me out :thumb: ?

Thanks !
Bertus.