I wonder if anyone can help me? I have a Flash photo gallery working from an XML file. The gallery has two types of photos, internal and external, described by the value 'type' in the XML file, like this:

<type>int</type> or <type>ext</type>

What I would like to be able to do is filter the images, when the user clicks either an 'Internal' or 'External' button, so that only the appropriate ones show.

I have tried reloading the XML then using

Code:
splice
to remove elements of the array where the value of <type> does not match the value of the filter, but the elements are not being removed.

I have also thought that I could check the type of each image as I click the 'NEXT' button to load each one, but I'm having trouble skipping more than one image, i.e. moving forward to the next image with the correct filter value.

Things are getting to the 'tearing out hair' stage, hence my post here. I would be very grateful if someone could suggest a workaround for this problem.

Thanks in advance

Andy.