I have created a picture slide show flash and put into a C# website project.
Here is my xml file
<?xml version="1.0" encoding="UTF-8" ?>
<flash_parameters copyright="socusoftFSMTheme">
<preferences>
<global>
<basic_property movieWidth="484" movieHeight="402" html_title="Title" loadStyle="Bar" startAutoPlay="true" continuum="true" socusoftMenu="false" backgroundColor="0x002780" hideAdobeMenu="false" photoDynamicShow="true" enableURL="false" transitionArray=""/>
<title_property showTitle="true" photoTitleColor="0x000080" backgroundColor="0xffffff" alpha="50" autoHide="true"/>
<music_property path="" stream="true" loop="true"/>
<photo_property topPadding="0" bottomPadding="0" leftPadding="0" rightPadding="0"/>
<properties enable="true" backgroundColor="0xffffff" backgroundAlpha="30" cssText="a:link{text-decoration: underline;} a:hover{color:#ff0000; text-decoration: none;} a:active{color:#0000ff;text-decoration: none;} .blue {color:#0000ff; font-size:15px; font-style:italic; text-decoration: underline;} .body{color:#ff5500;font-size:20px;}" align="top"/>
</global>
<thumbnail>
<basic_property showPreview="true" backgroundColor="0x000000" backgroundAlpha="70" buttonColor="0xffffff" numberColor="0x000000" currentNumberColor="0xffffff"/>
</thumbnail>
</preferences>
<album>
<slide jpegURL="ethumb/t_0001.jpg" d_URL="slides/p_0001.jpg" transition="0" panzoom="1" URLTarget="0" phototime="2" title="t-shirt" width="484" height="402"/>
<slide jpegURL="ethumb/t_0002.jpg" d_URL="slides/p_0002.jpg" transition="0" panzoom="1" URLTarget="0" phototime="2" title="golf" width="484" height="402"/>
<slide jpegURL="ethumb/t_0003.jpg" d_URL="slides/p_0003.jpg" transition="0" panzoom="1" URLTarget="0" phototime="2" title="ball" width="484" height="402"/>
<slide jpegURL="ethumb/t_0004.jpg" d_URL="slides/p_0004.jpg" transition="0" panzoom="1" URLTarget="0" phototime="2" title="shoe" width="484" height="402"/>
<slide jpegURL="ethumb/t_0005.jpg" d_URL="slides/p_0005.jpg" transition="0" panzoom="1" URLTarget="0" phototime="2" title="apu" width="484" height="402"/>
</album>
And the code i paste in my asp website
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="704" height="402" id="tech">
<param name="movie" value="flash home.swf?xml_path=home.xml" />
<param name="quality" value="high" />
<param name="wmode" value="opaque" />
<param name="swfversion" value="6.0.65.0" />
<object type="application/x-shockwave-flash" data="flash home.swf?xml_path=home.xml" width="704" height="402">
<param name="quality" value="high" />
<param name="wmode" value="opaque" />
<param name="swfversion" value="6.0.65.0" />
</object>
</object>
So, i want to allow user to insert a new “<“slide”>” into xml file between <“album”> <“/album”>.
Any help would be appreciate.
Sorry for my poor English.
Thank you.
Do you want this XML to be saved on your server, or just let the user temporarily add things to the local XML that was loaded into his .swf file?
If you want to save it on the server, you’ll need to add some sort of functionality to your website (or Flash file) that will let the user upload an image (or link to an image, doesn’t matter). You’ll need to add a element to your XML file and the embedded Flash object will need to reload it after it received a response from the server.
If you want just to let the user fiddle with his local copy of the XML, Flash provides libraries to work with XML Data. Check this link.
EDIT: Here is an example of how to add an element to an XML.