XML Driven

Hello World,
I'm interested in a photo stack gallery.
Here is an example: http://www.flashdevelopment.de/CONTENTS/3DPHOTOSTACKGALLERY02/3dphotostackgallery02.php
I want to use a photo stack gallery on my multiple affiliate websites to display my products.
What I want to be able to do is add and delete photos very fast, without having to fiddle around with xml or any other codes.
Can I do this with this product or is there some other simple, reliable and cheap product that I can?
Is a bulk preloader a code-work-around solution?
In other words does a bulk preloader make a photo stack gallery an image drag-and-drop photo stack gallery?
Said differently once more, is there a way to add multiple images fast to an xml driven photo stack gallery without fiddling around with xml code?
Thank you for your help,
Jerry

the xml will need to be edited to make changes to any xml-driven application whether that's a photo gallery or any other xml-driven application.
typically, you do that by opening up the xml file in a text editor and "fiddling" with code and then uploading the needed file(s) including the edited xml and the photo(s).   but an editor can be created (i make them using flash) that eliminates the need to fiddle with code ftp file uploads.
in the case of a photo gallery, you would:
1.  open the editor
2.  enter your password (because you don't want anyone else editing your gallery)
3.  you would be presented with an easy-to-use display - not code.
typically, for a photo gallery, that display would be:
1.  select a category (from a combobox), eg, shirts, pants, ties
2.  select one of 3 options, add, edit or delete
3.  if add was selected, you would be presented with
    a.  add after photo number.
    b.  add before photo number.
4. browse for file dialogue box would open so you could click on the file (on your computer), that you want to add.
5. a confirmation would appear (if all went well) that your photo was uploaded and added to your gallery.
6.  return to 1.
usually, there will be more involved (like a description/text) that should accompany the photo.  but that gives you the general outline of how a user-friendly editor would work.
if you want me to build one for you, send an email via my website:  www.kglad.com

Similar Messages

  • XML Driven Flash Photo Gallery Thumbnails

    Hi,
    I need to make a XML Driven Photo slide in Flash CS5.
    It needs to have a Box that contains 5 Thumbnails(by XML) act as buttons.
    The Box sits on top of the Main photo area and shrinks (or close out) when user click its close button. And it opens out by clicking on a open button.
    I'm sure it can be done by using timeline, Tweening or you name it..But what about the Thumbnails that run from the XML file?
    Can they disappear with the Box and retrieve when it opens? is it possible?
    If yes, what would be the best way to do that?
    Any comment would be greatly appreciated!
    Here is the ActionScript.
    import flash.net.URLRequest;
    import flash.net.URLLoader;
    import flash.events.Event;
    import fl.controls.Button;
    import flash.display.Shape;
    import flash.events.MouseEvent;
    import flash.display.MovieClip;
    import flash.display.Loader;
    import flash.text.TextField;
    import fl.transitions.*;
    import fl.transitions.easing.*;
    import flash.display.Shader;
    var hasloaded:Boolean = false;
    var firstLoaded:Boolean = false;
    var barWidth:int;
    var barHeight:int;
    var images;
    var imageCount:int;
    var thumbnailArray:Array = new Array();
    var bigImageArray:Array = new Array();
    var descriptionArray:Array = new Array();
    var xmlLoader:URLLoader = new URLLoader();
    var imageXML:XML = new XML();
    xmlLoader.addEventListener(Event.COMPLETE, LoadXML);
    xmlLoader.load(new URLRequest("slideshow.xml"));
    function LoadXML(e:Event):void {
        imageXML = new XML(e.target.data);
        ParseImages(imageXML);
    Populates the arrays with the image values
    and the text for each picture.
    function ParseImages(imageInput:XML):void {
        var iconList:XMLList = imageInput.image.icon;
        var mainImageList:XMLList = imageInput.image.mainimage;
        var descriptionList:XMLList = imageInput.image.description;
        for (var i:int = 0; i < iconList.length(); i++) {
            var imageElement:XML = iconList[i];
            //trace(imageElement);
            thumbnailArray[i] = imageElement;
        for (var j:int = 0; j < mainImageList.length(); j++) {
            var mainimageElement:XML = mainImageList[j];
            //trace(mainimageElement);
            bigImageArray[j] = mainimageElement;
        for (var l:int = 0; l < descriptionList.length(); l++) {
            var descriptionElement:XML = descriptionList[l];
            //trace(descriptionElement);
            descriptionArray[l] = descriptionElement;
        loadImages();
    function loadImages():void{
        trace("inside of loadimages function.");
        trace(thumbnailArray.length);
        for(var i:int=0; i < thumbnailArray.length; i++){
            trace(thumbnailArray[i]);
            populateContainers(thumbnailArray[i], i);
            //populateContainers2();
            trace("Loaded " + thumbnailArray[i]);
    var loader:Loader;
    var xStart = -210;
    var ypos = -34;
    var currentPos = xStart;
    var incrementValue = 66;
    This takes in the name of the image file and
    displays it within the newly created movie clip
    function populateContainers(file:String, pos:int):void{   
        //create a movie clip to hold the image
        var mc:MovieClip = new MovieClip();
        mc.graphics.beginFill(0xFFFFFF);
        mc.graphics.drawRect(0, 0, 50, 51);
        mc.graphics.endFill();
        mc.buttonMode = true;
        mc.x = currentPos;
        mc.y = ypos;
        mc.name = "thumb_" + pos;
        mc.addEventListener(MouseEvent.CLICK, clickHandler); 
        loader = new Loader();
        //loader.mask = imagemask;
        var url:URLRequest = new URLRequest(file);
        loader.contentLoaderInfo.addEventListener(Event.COMPLETE, loadInitialImage);
        loader.load(url);
        //add the image to the movie clip
        mc.addChild(loader);
        this.imageBar.addChild(mc);
        //increment the currentPos
        currentPos += incrementValue;
    function clickHandler(e:MouseEvent):void{
        var str:String = e.currentTarget.name;
        var index:int = int(str.substr(6,1));
        if(hasloaded) {
            this.mainWindow.removeChild(loader);
        loader = new Loader();
        loader.load(new URLRequest(bigImageArray[index]));
        this.mainWindow.addChild(loader);
        TransitionManager.start(this.mainWindow,{type:Fade, direction:Transition.IN, duration:2, easing:Regular.easeOut});
        //setChildIndex(loader, 0);
        hasloaded = true;
        loadText(index);
    function loadText(index:int):void {
        Object(this).imageBar.txtdescription.text = descriptionArray[index];
    function loadInitialImage(event:Event):void {
        if(!firstLoaded) {
            loader = new Loader();
            loader.load(new URLRequest(bigImageArray[0]));
            this.mainWindow.addChild(loader);
            TransitionManager.start(this.mainWindow,{type:Fade, direction:Transition.IN, duration:2, easing:Regular.easeIn});
            //setChildIndex(loader, 0);
            hasloaded = true;
            loadText(0);
        firstLoaded = true;
    /*  This section defines the buttons that control the image bar */
    Object(this).imageBar.btnBarOpen.addEventListener(MouseEvent.MOUSE_UP, openImageBar);
    function openImageBar(event:MouseEvent):void {
        this.gotoAndPlay(1);

    thank you!

  • XML Driven Flash Photo Gallery Thumbnails Control

    Hi, I need to make a XML Driven Photo slide in Flash CS5.
    It needs to have a Box that contains 5 Thumbnails(by XML) act as buttons.
    The Box sits on top of the Main photo area and shrinks (or close out) when user click its close button. And it opens out by clicking on a open button.
    I'm sure it can be done by using timeline, Tweening or you name it..But what about the Thumbnails that run from the XML file?
    Can they disappear with the Box and retrieve when it opens? is it possible?
    If yes, what would be the best way to do that?
    Any comment would be greatly appreciated!
    Here is the ActionScript.
    import flash.net.URLRequest;
    import flash.net.URLLoader;
    import flash.events.Event;
    import fl.controls.Button;
    import flash.display.Shape;
    import flash.events.MouseEvent;
    import flash.display.MovieClip;
    import flash.display.Loader;
    import flash.text.TextField;
    import fl.transitions.*;
    import fl.transitions.easing.*;
    import flash.display.Shader;
    var hasloaded:Boolean = false;
    var firstLoaded:Boolean = false;
    var barWidth:int;
    var barHeight:int;
    var images;
    var imageCount:int;
    var thumbnailArray:Array = new Array();
    var bigImageArray:Array = new Array();
    var descriptionArray:Array = new Array();
    var xmlLoader:URLLoader = new URLLoader();
    var imageXML:XML = new XML();
    xmlLoader.addEventListener(Event.COMPLETE, LoadXML);
    xmlLoader.load(new URLRequest("slideshow.xml"));
    function LoadXML(e:Event):void {
        imageXML = new XML(e.target.data);
        ParseImages(imageXML);
    Populates the arrays with the image values
    and the text for each picture.
    function ParseImages(imageInput:XML):void {
        var iconList:XMLList = imageInput.image.icon;
        var mainImageList:XMLList = imageInput.image.mainimage;
        var descriptionList:XMLList = imageInput.image.description;
        for (var i:int = 0; i < iconList.length(); i++) {
            var imageElement:XML = iconList[i];
            //trace(imageElement);
            thumbnailArray[i] = imageElement;
        for (var j:int = 0; j < mainImageList.length(); j++) {
            var mainimageElement:XML = mainImageList[j];
            //trace(mainimageElement);
            bigImageArray[j] = mainimageElement;
        for (var l:int = 0; l < descriptionList.length(); l++) {
            var descriptionElement:XML = descriptionList[l];
            //trace(descriptionElement);
            descriptionArray[l] = descriptionElement;
        loadImages();
    function loadImages():void{
        trace("inside of loadimages function.");
        trace(thumbnailArray.length);
        for(var i:int=0; i < thumbnailArray.length; i++){
            trace(thumbnailArray[i]);
            populateContainers(thumbnailArray[i], i);
            //populateContainers2();
            trace("Loaded " + thumbnailArray[i]);
    var loader:Loader;
    var xStart = -210;
    var ypos = -34;
    var currentPos = xStart;
    var incrementValue = 66;
    This takes in the name of the image file and
    displays it within the newly created movie clip
    function populateContainers(file:String, pos:int):void{ 
        //create a movie clip to hold the image
        var mc:MovieClip = new MovieClip();
        mc.graphics.beginFill(0xFFFFFF);
        mc.graphics.drawRect(0, 0, 50, 51);
        mc.graphics.endFill();
        mc.buttonMode = true;
        mc.x = currentPos;
        mc.y = ypos;
        mc.name = "thumb_" + pos;
        mc.addEventListener(MouseEvent.CLICK, clickHandler);
        loader = new Loader();
        //loader.mask = imagemask;
        var url:URLRequest = new URLRequest(file);
        loader.contentLoaderInfo.addEventListener(Event.COMPLETE, loadInitialImage);
        loader.load(url);
        //add the image to the movie clip
        mc.addChild(loader);
        this.imageBar.addChild(mc);
        //increment the currentPos
        currentPos += incrementValue;
    function clickHandler(e:MouseEvent):void{
        var str:String = e.currentTarget.name;
        var index:int = int(str.substr(6,1));
        if(hasloaded) {
            this.mainWindow.removeChild(loader);
        loader = new Loader();
        loader.load(new URLRequest(bigImageArray[index]));
        this.mainWindow.addChild(loader);
        TransitionManager.start(this.mainWindow,{type:Fade, direction:Transition.IN, duration:2, easing:Regular.easeOut});
        //setChildIndex(loader, 0);
        hasloaded = true;
        loadText(index);
    function loadText(index:int):void {
        Object(this).imageBar.txtdescription.text = descriptionArray[index];
    function loadInitialImage(event:Event):void {
        if(!firstLoaded) {
            loader = new Loader();
            loader.load(new URLRequest(bigImageArray[0]));
            this.mainWindow.addChild(loader);
            TransitionManager.start(this.mainWindow,{type:Fade, direction:Transition.IN, duration:2, easing:Regular.easeIn});
            //setChildIndex(loader, 0);
            hasloaded = true;
            loadText(0);
        firstLoaded = true;
    /*  This section defines the buttons that control the image bar */
    Object(this).imageBar.btnBarOpen.addEventListener(MouseEvent.MOUSE_UP, openImageBar);
    function openImageBar(event:MouseEvent):void {
        this.gotoAndPlay(1);

    thank you!

  • XML Driven Photo Gallery (Action Script Help)

    Hi,
    I need to make a XML Driven Photo slide in Flash CS5.
    It needs to have a Box that contains 5 Thumbnails(by XML) act as buttons.
    The  Box sits on top of the Main photo area and shrinks (or close out) when  user click its close button. And it opens out by clicking on a open  button.
    I'm sure it can be done by using timeline, Tweening or you name it..But what about the Thumbnails that run from the XML file?
    Can they disappear with the Box and retrieve when it opens? is it possible?
    If yes, what would be the best way to do that?
    Any comment would be greatly appreciated!
    Here is the ActionScript.
    import flash.net.URLRequest;
    import flash.net.URLLoader;
    import flash.events.Event;
    import fl.controls.Button;
    import flash.display.Shape;
    import flash.events.MouseEvent;
    import flash.display.MovieClip;
    import flash.display.Loader;
    import flash.text.TextField;
    import fl.transitions.*;
    import fl.transitions.easing.*;
    import flash.display.Shader;
    var hasloaded:Boolean = false;
    var firstLoaded:Boolean = false;
    var barWidth:int;
    var barHeight:int;
    var images;
    var imageCount:int;
    var thumbnailArray:Array = new Array();
    var bigImageArray:Array = new Array();
    var descriptionArray:Array = new Array();
    var xmlLoader:URLLoader = new URLLoader();
    var imageXML:XML = new XML();
    xmlLoader.addEventListener(Event.COMPLETE, LoadXML);
    xmlLoader.load(new URLRequest("slideshow.xml"));
    function LoadXML(e:Event):void {
         imageXML = new XML(e.target.data);
         ParseImages(imageXML);
      Populates the arrays with the image values
      and the text for each picture.
    function ParseImages(imageInput:XML):void {
         var iconList:XMLList = imageInput.image.icon;
         var mainImageList:XMLList = imageInput.image.mainimage;
         var descriptionList:XMLList = imageInput.image.description;
         for (var i:int = 0; i < iconList.length(); i++) {
             var imageElement:XML = iconList[i];
             //trace(imageElement);
             thumbnailArray[i] = imageElement;
         for (var j:int = 0; j < mainImageList.length(); j++) {
             var mainimageElement:XML = mainImageList[j];
             //trace(mainimageElement);
             bigImageArray[j] = mainimageElement;
         for (var l:int = 0; l < descriptionList.length(); l++) {
             var descriptionElement:XML = descriptionList[l];
             //trace(descriptionElement);
             descriptionArray[l] = descriptionElement;
         loadImages();
    function loadImages():void{
         trace("inside of loadimages function.");
         trace(thumbnailArray.length);
         for(var i:int=0; i < thumbnailArray.length; i++){
             trace(thumbnailArray[i]);
             populateContainers(thumbnailArray[i], i);
             //populateContainers2();
             trace("Loaded " + thumbnailArray[i]);
    var loader:Loader;
    var xStart = -210;
    var ypos = -34;
    var currentPos = xStart;
    var incrementValue = 66;
      This takes in the name of the image file and
      displays it within the newly created movie clip
    function populateContainers(file:String, pos:int):void{   
         //create a movie clip to hold the image
         var mc:MovieClip = new MovieClip();
         mc.graphics.beginFill(0xFFFFFF);
         mc.graphics.drawRect(0, 0, 50, 51);
         mc.graphics.endFill();
         mc.buttonMode = true;
         mc.x = currentPos;
         mc.y = ypos;
         mc.name = "thumb_" + pos;
         mc.addEventListener(MouseEvent.CLICK, clickHandler); 
         loader = new Loader();
         //loader.mask = imagemask;
        var url:URLRequest = new URLRequest(file);
         loader.contentLoaderInfo.addEventListener(Event.COMPLETE, loadInitialImage);
         loader.load(url);
         //add the image to the movie clip
         mc.addChild(loader);
         this.imageBar.addChild(mc);
         //increment the currentPos
         currentPos += incrementValue;
    function clickHandler(e:MouseEvent):void{
         var str:String = e.currentTarget.name;
         var index:int = int(str.substr(6,1));
         if(hasloaded) {
             this.mainWindow.removeChild(loader);
         loader = new Loader();
         loader.load(new URLRequest(bigImageArray[index]));
         this.mainWindow.addChild(loader);
         TransitionManager.start(this.mainWindow,{type:Fade, direction:Transition.IN, duration:2, easing:Regular.easeOut});
         //setChildIndex(loader, 0);
         hasloaded = true;
         loadText(index);
    function loadText(index:int):void {
         Object(this).imageBar.txtdescription.text = descriptionArray[index];
    function loadInitialImage(event:Event):void {
         if(!firstLoaded) {
             loader = new Loader();
             loader.load(new URLRequest(bigImageArray[0]));
             this.mainWindow.addChild(loader);
             TransitionManager.start(this.mainWindow,{type:Fade, direction:Transition.IN, duration:2, easing:Regular.easeIn});
             //setChildIndex(loader, 0);
             hasloaded = true;
             loadText(0);
         firstLoaded = true;
    /*  This section defines the buttons that control the image bar */
    Object(this).imageBar.btnBarOpen.addEventListener(MouseEvent.MOUSE_UP, openImageBar);
    function openImageBar(event:MouseEvent):void {
         this.gotoAndPlay(1);

    Well Thats what i know but you might be able to use flash player 10 in your browser i think the file system works on it fine im not sure i mostly work on air glad i could help
    James

  • Flash Lite XML Driven Gallery Simple Question

    Hello Flash Lite Gurus',
    Someone Named "Mr. Samir K. Dash;" did a wonderful tutorial regarding Flash Lite XML driven Photo Gallery, and I have just a small question:
    1> I changed the attributes schema of the xml as attached and noticed that it is not working, and I wonder what could be the reason (please see the attached XML new attribute schema, I didn't change fields names, I just changed the way the attributes' schema looks like).
    The link to the tutorial is the following:
    http://www.adobe.com/devnet/devices/articles/xml_photo_gallery.html
    Looking forward to your help
    best regards
    Talal

    As I look at your modified XML file, you need to make major changes in the script.
    You have changed the attributes to become child nodes. So, you will need to use firstChild.nodeValue or childNodes[i].nodeValue everywhere.
    Regards,
    Hemanth Sharma
    http://www.flashlitehub.com/blog

  • Creating a very simple XML-driven gallery

    Hi, I'm learning XML in AS3 and I am having real trouble finding a resource that can help me learn how to build a very simple XML-driven picture gallery.
    I am working in an FLA file with AS3, with a dynamic text field with the instance name "textfield". I also have a UILoader Component with the instance name "UILoaderComponent" and an XML file called "rootdir.xml".
    I have an XML file in the following format.
    <images>
         <imagenames>
              <name>image1</name>
              <name>image2</name>
              <name>image3</name>
              <name>image4</name>
              <name>image5</name>
         </imagenames>
         <imagepaths>
              <path>image1.jpg</path>
              <path>image2.jpg</path>
              <path>image3.jpg</path>
              <path>image4.jpg</path>
              <path>image5.jpg</path>
         </imagepaths>
    </images>
    I am using the following as my actionscript.
    var xmlLoader:URLLoader = new URLLoader();
    var xmlData:XML = new XML();
    xmlLoader.addEventListener(Event.COMPLETE, LoadXML);
    xmlLoader.load(new URLRequest("rootdir.xml"));
    function LoadXML(e:Event):void {
    xmlData = new XML(e.target.data);
    parseImg(xmlData);
    function parseImg(imgLoad:XML):void {
    var imgChild:XMLList = imgLoad.images.children();
    for each (var imgTrace:XML in imgChild) {
    trace(imgTrace);
    No matter which way I experiment, I always have poor results with my dynamic text, and every tutorial I've followed does not reproduce anything like the same returned data in "textfield" that it does with the trace command.
    My objective is: I simply want to build a menu inside a textbox called "textfield" that lists images1-5, and when clicked, calls upon the relevant image. For instance: I load the file "rootdir.xml" into the file "index.fla". I call a function to parse the XML into a dynamic text box called "textfield". When image 2 is clicked on the textbox "textfield", it would call upon a function that would load into the UIComponent Loader "image2.jpg".
    Are there any tutorials for this? I'm so confused as to why dynamic text operates so differently from the trace command. I'm not interested in doing a fancy menu bar with thumbnails, scrollbars and animations, I just want to learn the basics.

    I don't really see how you are getting a valid trace out of that code (I get nothing if I try it as is), but as far as the textfield goes, you haven't shown any attempt in your code that might help to point to why you cannot get the text into a textfield.  It might be a problem with how you are trying to write to the textfield and not how your are manipulating the data.
    While you could make use of a textfield for the menu, doing so is not straightforward, as you would need to implement htmlText with special coding in order to have the text clickable.  You might consider using a List component or ComboBox instead.
    What I always do when I am working with xml is to store the data into a data structure, usually an array conatining objects, and then make use of that structure rather than dippng into the xml data itself when I utilize the data.
    Another thing, which rquigley demonstrated, is that your xml will serve its purpose better if the data for each image is collected under the same node.  If you have separate sections for each piece of data like you have, when it comes to editing it will be more prone to error as you have to be sure you are editing the correct entry of each separate group.
    I too am no expert in the world of xml, but I have not yet worked with parameters inside the tags, so I would usually structure it as...
    <images>
       <image>
           <imgName>image 1</imgName>
           <imgPath>image1.jpg</imgPath>
       </image>
       <image>
           <imgName>image 2</imgName>
           <imgPath>image2.jpg</imgPath>
       </image>
    </images>
    Now, back to what you have...  let's say you have a textField named imgText that you want to list the image names in.  The following should work, though I do not go my usual route of storing the data into an object array first...
    function parseImg(imgLoad:XML):void {
       var imgNames:XMLList = imgLoad.imagenames.name;
       var imgPaths:XMLList = imgLoad.imagepaths.path;
       // show name
       for each (var nameTrace:XML in imgNames) {
          trace(nameTrace);
          imgText.appendText(nameTrace +"\n");
       // show path
       for each (var pathTrace:XML in imgPaths) {
          trace(pathTrace);
          imgText.appendText(pathTrace +"\n");
       // show name and path
       for(var i:uint=0; i<imgNames.length(); i++){
          trace(imgNames[i].text()+"  "+imgPaths[i].text());
          imgText.appendText(imgNames[i].text()+"  "+imgPaths[i].text() +"\n");

  • Importing xml driven swf file -- is it asking for too much?

    I want to import an ActionScript3 / xml driven swf file into Catalist, but it only imports the swf file.
    I have placed all the external images and the xml file that calls them into the same folder as the swf and the catalist files, but the playback still does not work. It shows error messages when trying to run. Copying the files to Assets/ Media  or Images folders also makes no difference...There is no way in Catalyst to reconnect the xml to the swf either...
    Why can't Flash and Catalyst be more friendly? Will there be a better connectivity in the final version?

    Hello there,
    There are several reasons why this wouldn't work, especially during preview. I'd like to ask you a couple questions and have you try a couple things.
    1. What file path are you saving your project to, and what location did you copy the XML and image files to?
    2. Did you try publishing your project, and copying your additional files to the published locations?
    3. Did you try the same steps as above, only using the deploy-to-web version posted on your server? You would load the application by going to your web browser and typing something like: http://yourserverhere.com/.../deploy-to-web/Main.html.
    Let me know if any of those work. Because Catalyst cleans the space where preview files are kept, it would be difficult to have your scenario work during preview. However, you could probably get it to work in a published version.

  • XML driven DataGroup & lastResult or selected item

    I am using a xml driven DataGroup to display images with a itemRenderer and custom layout. When an image is selected i want a new state to display with info from the selected item (image, name, description). Is this possible and how do i do it?
    code example;
              <s:HTTPService id="srv" url="http://...../data/catalog.xml" result="resultHandler(event)" />
              <s:DataGroup includeIn="Main" left="50" right="50" top="200" dataProvider="{items}" id="dg1"
                     horizontalCenter="0" itemRenderer="renderers.kitchensRenderer" click="currentState='details'">
                           <s:layout>
                               <layouts:FilteredTileLayout id="filterLayout" filteredItems="{filteredItems}" />
                           </s:layout>
              </s:DataGroup>
              <mx:Image id="image2" includeIn="details" width="720" height="450" top="75" horizontalCenter="0" src="???" />               how do i get the selected DataGroup item to display the correct image
               //kitchensRenderer
              <mx:Image id="image" width="72" height="45" horizontalCenter="0" source="{data.image}" />

    "implement the property in your model and update the renderer state based on that."
    I am a complete beginner and most of the code I got from TourDeFlex. Please can you explain how to do this or provide a code example, thanks

  • Player help - xml driven mp3

    Hi,
    I have been working on a different effect for a xml driven
    mp3 mini player; it consists of three buttons that plays, pauses
    and unpauses. Only one button is displayed on screen, to its user.
    Now the problem I've got is that when the song ends, the button
    shown is either pause or unpause; due to once the play button is
    initially pressed its visibility is set to false. Now, when the
    songs ends it stops until the user clicks the play button; however
    the play button at present is invisible; so I need a way to display
    the play button when the song ends, so the user can start it again,
    and pause and unpause as normal.
    I have attached the code.
    Quite a challenge, but the effect will be unique. Clbeech
    where are you?
    Kind Regards,
    Boxing Boom

    Hi,
    Nice try, but doesn't resolve the problem. You als forgot to
    add the playSong() function to the play button; So I added it as
    follows;
    //this is the 'play' button
    toggleSound1_btn.onRelease = function() {
    playSong();
    toggleSound2_btn._visible = true;
    this._visible = false;
    And the rest of the code does exactly what it done in the
    first place. But many thanks for trying this for me, I really do
    appreciate you help.
    What we got here, is a RUBICS CUBE! It is mindgame for me!
    Aaaghh! How can a little sound player script be so hard, this is
    not right, is it?
    This is how my layers is set up; Actions, Play, Pause,
    Unpause. This has nothing to do with the problem at hand?
    Kind Regards,
    Boxing Boom

  • XML Driven Video Gallery with Playlist

    Hi,
    I have put together a XML Driven Video Player with auto thumbnail detection but there is a problem.The Video plays but, The thumbs will not show. I think my thumbnail function is not reaching the correct node in my XML.Can someone take a look at my Actionscript Please? The Action Script is below. The XML is at the bottom of this post. The top half of the code is the video playing code the bottom is for the thumbs.
    Actionscript 2.0
    var nc:NetConnection = new NetConnection();
    nc.connect(null);
    var ns:NetStream = new NetStream(nc);
    ns.setNufferTime(30);
    ns.onStatus = function(info) {
    if (info.code == "NetStream.Buffer.Full") {
    bufferClip._visible = false;
    if (info.code == "NetStream.Buffer.Empty") {
    bufferClip._visible = true;
    if (info.code == "NetStream.Buffer.Stop") {
    ns.seek(0);
    theVideo.attachVideo(ns);
    rewindButton.onRelease = function() {
    ns.seek(0);
    playButton.onRelease = function() {
    ns.pause();
    var videoInterval = setInterval(videoStatus, 100);
    var amountLoaded:Number;
    var duration:Number;
    ns["onMetaData"] = function (obj) {
    duration = obj.duration;
    function videoStatus() {
    amountLoaded = ns.bytesLoaded/ns.bytesTotal;
    loader.loadbar._width = amountLoaded*187.4;
    loader.scrub._x = ns.time/duration*187.4;
    var scrubInterval;
    loader.scrub.onPress = function() {
    clearInterval(videoInterval);
    scrubInterval = setInterval(scrubit, 10);
    this.startDrag(false,0,this._y,187.4,this._y);
    loader.scrub.onRelease = loader.scrub.onReleaseOutside=function () {
    clearInterval(scrubInterval);
    videoInterval = setInterval(videoStatus, 100);
    this.stopDrag();
    function scrubit() {
    ns.seek(Math.floor((loader.scrub._x/187)*duration));
    var theMenu:ContextMenu = new ContextMenu();
    theMenu.hideBuiltInItems();
    _root.menu = theMenu;
    var i1:ContextMenuItem = new ContextMenuItem(":::::Video Controls:::::", trace);
    theMenu.customItems[0] = i1;
    var i2:ContextMenuItem = new ContextMenuItem("Play / Pause Video", pauseIt, true);
    theMenu.customItems[1] = i2;
    var i3:ContextMenuItem = new ContextMenuItem("Replay Video", replayIt);
    theMenu.customItems[2] = i3;
    var i4:ContextMenuItem = new ContextMenuItem("All Rights Reserved 2009", trace, true);
    theMenu.customItems[3] = i4;
    var i5:ContextMenuItem = new ContextMenuItem("SamAndOnline.com Video Player", trace);
    theMenu.customItems[4] = i5;
    function pauseIt() {
    ns.pause();
    function replayIt() {
    ns.seek(0);
    //sound controls
    _root.createEmptyMovieClip("vSound",_root.getNextHighestDepth());
    vSound.attachAudio(ns);
    var so:Sound = new Sound(vSound);
    so.setVolume(100);
    volControl.volcon.slider1.onPress = function() {
    this.startDrag(true,volControl.volcon.groove1._x,volControl.volcon.groove1._y,volControl.v olcon.groove1._x,volControl.volcon.groove1._y+100);
    slideit = setInterval(volControl.volcon.slider_1Move, 100, this);
    volControl.volcon.slider1.onRelease = function() {
    this.stopDrag();
    clearInterval(slideit);
    mute.gotoAndStop("on");
    volControl.volcon.slider1.onReleaseOutside = function() {
    this.stopDrag();
    clearInterval(slideit);
    mute.gotoAndStop("on");
    mute.onRollOver = function() {
    if (so.getVolume() == 100) {
    this.gotoAndStop("onOver");
    } else {
    this.gotoAndStop("muteOver");
    mute.onRollOut = function() {
    if (so.getVolume() == 100) {
    this.gotoAndStop("on");
    } else {
    this.gotoAndStop("mute");
    mute.onRelease = function() {
    if (so.getVolume() == 100) {
    so.setVolume(0);
    this.gotoAndStop("muteOver");
    } else {
    so.setVolume(100);
    this.gotoAndStop("onOver");
    //listBx
    var vlist:XML = new XML();
    vlist.ignoreWhite = true;
    vlist.onLoad = function() {
    var videos:Array = this.firstChild.childNodes;
    for (i=0; i<videos.length; i++) {
    videoList.addItem({label:videos[i].attributes.desc,data:videos[i].attributes.url ,image:videos[i].attributes.thumb});
    //play 1st video
    ns.play(videoList.getItemAt(0).data);
    videoList.selectedIndex = 0;
    //would like to reference something in the XML File with the thumb attribute
    thumbnails_fn(i);
    var vidList:Object = new Object();
    vidList.change = function() {
    ns.play(videoList.getItemAt(videoList.selectedIndex).data);
    videoList.addEventListener("change",vidList);
    vlist.load("videos.xml");
    soundb.onRelease = function() {
    if (volControl.switch2=open2) {
    volControl.gotoAndPlay("open");
    } else {
    volControl.play();
    function thumbNailScroller() {
    // thumbnail code!
    this.createEmptyMovieClip("tscroller", 1000);
    scroll_speed = 10;
    tscroller.onEnterFrame = function() {
    if ((_root._ymouse>=thumbnail_mc._y) && (_root._ymouse<=thumbnail_mc._y+thumbnail_mc._height)) {
    if ((_root._xmouse>=(hit_right._x-40)) && (thumbnail_mc.hitTest(hit_right))) {
    thumbnail_mc._x -= scroll_speed;
    } else if ((_root._xmouse<=40) && (thumbnail_mc.hitTest(hit_left))) {
    thumbnail_mc._x += scroll_speed;
    } else {
    delete tscroller.onEnterFrame;
    function thumbnails_fn(k) {
    thumbnail_mc.createEmptyMovieClip("t"+k, thumbnail_mc.getNextHighestDepth());
    tlistener = new Object();
    tlistener.onLoadInit = function(target_mc) {
    target_mc._x = hit_left._x+(eval("thumbnail_mc.t"+k)._width+5)*k;
    target_mc.pictureValue = k;
    target_mc.onRelease = function() {
    p = this.pictureValue-1;
    nextImage();
    target_mc.onRollOver = function() {
    this._alpha = 50;
    thumbNailScroller();
    target_mc.onRollOut = function() {
    this._alpha = 100;
    image_mcl = new MovieClipLoader();
    image_mcl.addListener(tlistener);
    image_mcl.loadClip(image[k], "thumbnail_mc.t"+k);
    trace(videoList.getItemAt(0).image+ "k= "+k+" "+videos.length+" pv "+target_mc.pictureValue+" thumbnails");
    XML Example
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <videos>
    <video url="vid1.flv" desc="Video 1" thumb="1.jpg"/>
    <video url="vid2.flv" desc="Video 2" thumb="2.jpg"/>
    </videos>

    I'm trying to load the thumbnails in with this code
    image_mcl.loadClip(image[k], "thumbnail_mc.t"+k);
    i tried
    videoList.getItemAt(k).image
    which works in the trace method but gives no response in the actual code it self
    So the line of code that should work is
    image_mcl.loadClip(videoList.getItemAt(k).image, "thumbnail_mc.t"+k);
    and not
    image_mcl.loadClip(image[k], "thumbnail_mc.t"+k);
    but I gets no response

  • XML driven Accordion is it possible?

    Hi,
    An XML driven Accordion is it possible?
    If so does anyone know a good tutorial?
    Any help is greatly appreciated.

    I am familiar with with creating and loading an xml file.
    I never touched the accordian component though.
    Is it also possible to let the accordeon dynamicaly grow/thrink as the XML holds more or less data?
    I will try it out
    Thanks

  • XML Driven 3D Animated Flash Charts

    Hi,
    I want to create a 3d XML driven animated chart. Can anyone help me for that?
    Thanks
    Pinal

    I do have pretty good idea. But it is unrealistic to expect someone will walk you through development of entire application.
    Charts, especially 3D charts, are quite advanced tasks and require deep knowledge of ActionScript and its Graphics functionality along with trigonometry and 3D concepts/techniques.
    If you just need charts - you can use available packages. Charts come with Flash Builder. Yahoo has its free astra charts. You may want to use them.

  • XML driven flv player

    Hi,
    I need to create an XML driven flv player, now I know how to
    construct the player, but not sure of the code for the XML to hold
    just one flv file, not a list of them just the one.
    I need my flv player to play just one flv file; as soon as
    its run on the web, it needs to play only one flv video. No need to
    pick it from any list etc... This way the client can simply edit
    the XML file to play a different flv video.
    Kind Regards,
    Boxing Boom

    Boxing Boom,
    You are correct about error
    AS3
    Error #1093 being because of the quotes. The unfortunate thing
    is that this error doesn't give any further info. I have created a
    blog post specifically about error
    ActionScript
    Error #1093 There are a few other reasons that a Flasher will
    get this error. Hope this is helpful.
    Curtis J. Morley

  • XML-driven sites & Google

    Hello!
    I was just wondering if anyone has any experience with how
    Google handles sites that take all of their text-content from a XML
    file. As far as I experienced by now Google is able to read the
    text in standard SWFs, but will it "pre-render" a XML-driven SWF?
    Thanks!

    > I was just wondering if anyone has any experience with
    how Google handles
    > sites that take all of their text-content from a XML
    file. As far as I
    > experienced by now Google is able to read the text in
    standard SWFs, but
    > will
    > it "pre-render" a XML-driven SWF?
    Google traverses documents searching for texts and links and
    then index only
    those documents which are linked (internally or externally).
    If SWF
    communicates with server in background via XML then this
    document stays "top
    secret" and will not be indexed without special activity done
    by yourself
    (SEO techniques). Another issue is "Google is able to read
    SWFs".
    Technically it's is true but this kind of contents is very
    poor and ranking
    of it is usually hopeless.

  • Looking for a non XML driven Flash banner rotator

    I am looking for a non XML driven Flash banner rotator, something where I can load my images into the FLA and publish. The only rotators I can seem to find have external XML/image files, etc.
    All I want to do is create simple SWF's that I can use to display rotating images preferably is a smooth and stylish manner. Does anyone know of any, or could point me in the right direction?
    Many thanks for any help you may be able to offer and I am willing to follow any tutorials.

    Hi
    I wonder why not show you how to use Quicktime.
    Because I would use the html5 audio, that way the browser chooses the 'player' to use, and I wanted to give the OP the choice -
    <audio controls preload="auto" autobuffer>
      <source src="elvis.mp3" />
      <source src="elvis.ogg" />
      <!-- now include flash fall back -->
    </audio>
    PZ

Maybe you are looking for

  • LaCie DVR compatible with Digital Audio?

    I'm looking for a FW DVD/CD burner that will be compatible with my G4 Digital Audio, 466 MHz. Requirements for the LaCie d2 DVD FW dual layer with LightScribe state 500 MHz. Will the drive work even though my speed is slightly slower? I would also li

  • Help! Pressing Command and Q always launches Safari

    Hi, Today, out of nowhere, if I try to Quit an application other than Safari using the Command and Q keys on the keyboard, it doesn't work. What it does is launch Safari. I don't know how to get it to stop doing that. Does anyone know? Thanks in adva

  • Can't shutdown as user

    Hi, I just followed the Wiki-Entry on how to make users able to shutdown/reboot the system, but I get the following error: user /home/user $ sudo halt sudo: sorry, you are not allowed to preserve the environment My sudoers file: Defaults:user timesta

  • List PO's waiting to be released

    Hi, Is there a standard report to list the PO's waiting to be released ? If not, which tables should I look into to create this list myself in QuickViewer ? Thanks in advance for your feedback, Erik

  • New printer install problems

    Bought a Laserjet pro 400, M451dn and it is not installing