PDA

View Full Version : desperate xml help


Lionel
03-22-2007, 01:57 AM
I have these nodes

<gallery id="2" title="News" description="My News">
<img align="center" src="/forums/attachment.php?attachmentid=7738" thumb="/forums/attachment.php?attachmentid=7738" title="My title" caption="Insert intro here" link="http://www.site.com" />
<img align="center" src="/forums/attachment.php?attachmentid=7787" thumb="/forums/attachment.php?attachmentid=7787" title="My other title" caption="Insert intro here" link="http://www.site.com" />
</gallery>

<gallery id="3" title="News" description="My News">
<img align="center" src="/forums/attachment.php?attachmentid=7738" thumb="/forums/attachment.php?attachmentid=7738" title="My title" caption="Insert intro here" link="http://www.site.com" />
<img align="center" src="/forums/attachment.php?attachmentid=7787" thumb="/forums/attachment.php?attachmentid=7787" title="My other title" caption="Insert intro here" link="http://www.site.com" />
</gallery>
and so on


I'd like to be able to write only to a specific node.

for example id is forumid. I am creating a plugin to: When I post a thread which meets certain conditions in a forumid, I want to be able to run my query and insert it in the approriate node

<gallery id="xx" ...>

</gallery>

I am stucked big time on how to target that specific node. I've tried fopen, i've tried the new xml function (am on php 5.16) and am not too familiar with it.

Can someone, please help me?