# Shadowbox from xml not hard code

**URL:** <https://forum.kirupa.com/t/shadowbox-from-xml-not-hard-code/283395>\
**Category:** Uncategorized\
**Created:** [March 5, 2009, 4:41pm UTC](https://forum.kirupa.com/t/shadowbox-from-xml-not-hard-code/283395 "2009-03-05T16:41:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![diggz](https://avatars.discourse-cdn.com/v4/letter/d/67e7ee/32.png) [@diggz](https://forum.kirupa.com/u/diggz)\
**Post date:** [March 5, 2009, 4:41pm UTC](https://forum.kirupa.com/t/shadowbox-from-xml-not-hard-code/283395/1 "2009-03-05T16:41:39Z")

</div>

hi all - i am trying to get shadowbox working from flash with as3 and xml

i have found a method that works for as3 which is this

```auto
	ExternalInterface.call("openShadowbox",'http://www.google.com/','iframe','Title');

```

but what i am trying to work out is how adapt this script to open shadowbox instead of lightwindow through xml - like this script does

```auto
var script:XML =
<script>
    <![CDATA[
             function(url, title_list, description_list, rel_list)
             {
                myLightWindow.activateWindow({href: url,
                                             title: title_list});
             }
             ]]>
</script>;

function p_click(me:MouseEvent)  
{  
    var sp:Sprite = me.target as Sprite;
    var s_no:Number = parseInt(sp.name.slice(8,10));
    trace("rel is '"+rel_list[s_no]+"'");ExternalInterface.call(script, url_list[s_no], title_list[s_no], description_list[s_no], rel_list[s_no]);
} 

```

i guess i need to create the params for shadowbox file type etc…

but i don’t know how this needs to be written now?

```auto
myLightWindow.activateWindow

```

or if the secret lies in the p\_click mouseevent script?  
anyone see what i need to do?
