shadowbox from flash using XML

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

shadowbox from flash using XML

taihan
This post was updated on .
Hi guys,
I'm dying with this one.I have searched everywhere but didn't find anything similar. K I want to run shadowbox through my flash file and use the category function from shadowbox at the same time. The Images are loaded through a XML file. It's working so fare, but I can't seem to group my images. I just menage to display a single one at a time. Well here is the code I used so fare.Hope you can help me out!

THANKS

----------------------------------------------------------------------------------------------
AS:

var dat = new Array();
var n = XMLData1.firstChild.firstChild;
while (n != null)
{
    if (n.nodeName == "file")
    {
        var cob = new Object();
        for (var i in n.childNodes)
        {
            var m = n.childNodes[i];
            cob[String(m.nodeName)] = String(m.firstChild.nodeValue);
        } // end of for...in
        dat.push(cob);
    } // end if
    n = n.nextSibling;
} // end while
mask_mc._width = slider._width;
mask_mc._height = Stage.height;
hit_mc._width = slider._width;
hit_mc._height = Stage.height;
hit_mc._alpha = 0;
container_mc.setMask(mask_mc);
var cm = container_mc;
var erxi;
var erxf;
var j = 0;
while (j < dat.length)
{
    var d = cm.getNextHighestDepth();
    var ct = cm.attachMovie("digital_thumbnail", "t" + j, d);
    ct.animate();
    ct._y = 12;
    ct.pic_mc.picHolder_mc.loadMovie(dat[j].image);
    ct.ref_mc.picHolder_mc.loadMovie(dat[j].image);
    if (j == 0)
    {
        erxi = Math.round((ct.pic_mc.picHolder_mc._width - 58) / 2);
        if (erxi < 0)
        {
            erxi = 0;
        } // end if
    } // end if
    if (j == dat.length - 1)
    {
        erxf = Math.round((ct.pic_mc.picHolder_mc._width - 58) / 2);
        if (erxf < 0)
        {
            erxf = 0;
        } // end if
    } // end if
    ct._x = erxi + 12 + 100 * j;
    ct.url = dat[j].url;
ct.onRelease = function ()
    {
        getURL("javascript:openShadowbox('img','" + this.url +"','Title');","_self")      
    };

------------------------------------------------------------------------------------------
XML:

<dock>
        <file>
                <image>images/tumb_v19.png</image>
                <url>images/v19.jpg</url>
        </file>
        <file>
                <image>images/tumb_v20.png</image>
                <url>images/v20.jpg</url>
        </file>
        <file>
                <image>images/tumb_v18.png</image>
                <url>images/v18.jpg</url>
        </file>
        <file>
                <image>images/tumb_v4.png</image>
                <url>images/v4.jpg</url>
        </file>
</dock>

------------------------------------------------------------------------------------------------
HTML:

<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=windows-1251" />
<script type="text/javascript" src="js/jquery-1.2.6.js"></script><script type="text/javascript" src="js/shadowbox-jquery.js"></script><script type="text/javascript" src="js/shadowbox.js"></script>  <script type="text/javascript"> Shadowbox.loadSkin('classic', 'build/skin'); Shadowbox.loadLanguage('en', 'build/lang'); Shadowbox.loadPlayer(['flv', 'html', 'iframe', 'img', 'qt', 'swf', 'wmp'], 'build/player'); var openShadowbox = function(player, gallery, content, title){ Shadowbox.init({skipSetup: true}); Shadowbox.open({ player: player, content: content, title: title }); }; </script>
Reply | Threaded
Open this post in threaded view
|

Re: shadowbox from flash using XML

taihan
anyone?
Reply | Threaded
Open this post in threaded view
|

Re: shadowbox from flash using XML

taihan
In reply to this post by taihan
20 views and still no one able to help? mmmh..hope someone will be so kind
Reply | Threaded
Open this post in threaded view
|

Re: shadowbox from flash using XML

JUNE
In reply to this post by taihan
I noticed on your site it looks like its working..?
http://www.kiwiarts.de/en.html

I am looking for a working example of xml and shadowbox.

What was your outcome?
Can you send me a working example?

email: juneink@gmail.com

Reply | Threaded
Open this post in threaded view
|

Re: shadowbox from flash using XML

James
In reply to this post by taihan
Was there any resolution to thi issue?

I have a flash site that calls shadowbox local iframe (html pages), swfs and video files.  i was able to get it working.  however, all links need to be hardcoded into the actionscript themselves.

this is fine, however, whenever I need to update something, i have to republish the flash file.

It would be nice to be able to update an xml file to ease in updating of the site.

is this possible?

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: shadowbox from flash using XML

kuchki ness
James!, could you post a working example of what you did with flash and opening html in iframe, i need it so badly. i cant make it work.
Reply | Threaded
Open this post in threaded view
|

Re: shadowbox from flash using XML

argee
In reply to this post by taihan
Hey taihan,
have you detached the problem?

I've searching for this too, but I found any resolution. The only think I everytime heared is, js can't read xml
so i think push an array from flash with the hole gallery group data to the html-file and js can grab the data from html for viewing groups.