Skip to main content
Known Participant
June 29, 2013
Answered

how i can add description tag in xml gallery

  • June 29, 2013
  • 1 reply
  • 1006 views

my xml is....................

<?xml version="1.0" encoding="utf-8"?>

<?xml-stylesheet href="xmldesign.css" type="text/css"?>

<gallery thumb_width="400" thumb_height="290" gallery_width="400" gallery_height="700" gallery_x=" " gallery_y=" " full_x="1220" full_y="50" >

<image thumb_url="t1.jpg"  full_url="full01.jpg" title="Mango Juice"/>

<image thumb_url="t2.jpg"  full_url="full01.jpg" title="Mango Juice"/>

<image thumb_url="t3.jpg"  full_url="full01.jpg" title="Mango Juice"/>

<image thumb_url="t4.jpg"  full_url="full01.jpg" title="Mango Juice"/>

<image thumb_url="t5.jpg"  full_url="full01.jpg" title="Mango Juice"/>

<image thumb_url="t6.jpg"  full_url="full01.jpg" title="Mango Juice"/>

</gallery>

This topic has been closed for replies.
Correct answer Ned Murphy

You could modify each tag in a similar manner as follows....

<image thumb_url="t6.jpg"  full_url="full01.jpg" title="Mango Juice" desc="description here" />

1 reply

Ned Murphy
Ned MurphyCorrect answer
Legend
June 29, 2013

You could modify each tag in a similar manner as follows....

<image thumb_url="t6.jpg"  full_url="full01.jpg" title="Mango Juice" desc="description here" />

Known Participant
June 29, 2013

but where i put it on my function

my function is---

..............

.............

fullPreloader.onLoadStart = function(target)

    {

        target.createTextField("my_txt",ajit.getNextHighestDepth(),20,0,700,20);

        my_txt.selectable = true;

       

       

    };

    fullPreloader.onLoadProgress = function(target, loadedBytes, totalBytes)

    {

        target.my_txt.text = Math.floor((loadedBytes / totalBytes) * 00);

    };

    fullPreloader.onLoadComplete = function(target)

    {

        new Tween(target, "_alpha", Strong.easeOut, 60, 100, .5, true);

        target.my_txt.text = myTitle;           //////          this is my title

       

    };

    fullClipLoader.loadClip("full_images/" + myURL,ajit);

}

Ned Murphy
Legend
June 29, 2013

Look at the rest of your code where you extract the title and the file name.  THat should be enough for you to figure out what you need to do.

function callFullImage(myNumber)

{

    myURL = myImages[myNumber].attributes.full_url;

    myTitle = myImages[myNumber].attributes.title;

   myDesc = ..... figure this out based on the above