Topic: Amend the PHP script NOT to overide the captions

Great application and thanks for being so generous as to share it with us!

I think it would be most beneficial if the PHP script is amended so as everytime it runs to update the XML file with the image content that it does not override existing images that have captions attached to them.  This would avoid the redundancy of downloading the xml file again and reinserting the captions of the old files.

So the PHP script would intelligently check existing images in the Images folder and if they are already referenced in the XML file they are left. I guess however this depends if the PHP file is set to write to the XML file rather than create a fresh one each time. Just a thought.

Re: Amend the PHP script NOT to overide the captions

Good idea! Anyone care to take a stab at it?

Felix Turner
SimpleViewer Support Team.

Re: Amend the PHP script NOT to overide the captions

Hi Felix.

I'm new on the forum, but I was using SimpleViewer fro quite some time. Will gladly look at the PHP creation script to add this feature maybe next week or so. Although I never actually used it, since I'm using custom made CMS for my galleries, hence everything is dynamic.

Re: Amend the PHP script NOT to overide the captions

Any updates on this? I would love this feature as well.

Re: Amend the PHP script NOT to overide the captions

Sorry for the delay. Didn't have the time to play with PHP in a while and also don't use this script by myself, hence I only had a chance yesterday to look into it. Since PHP 4 and 5 handle XML differently I am parsing the XML as a text file. Not the best way to do it, but should work fine both in 4 and 5. Anyway, give it a try and let me know if it worked for you.

For whatever reason I cannot post links here anymore. Will try to post it in the next message.

Re: Amend the PHP script NOT to overide the captions

The modified script is here:

http://s177737956.onlinehome.us/simplev … ptions.zip

Re: Amend the PHP script NOT to overide the captions

WORKS GREAT! THANKS SHKIN!! This should be included by default, Felix.

Re: Amend the PHP script NOT to overide the captions

Not to look a gift horse in the mouth, but I can't get the version of the script above to work. As I'm not a PHP expert, I'm not really qualified to debug it sad If somebody has it working or may know what the issue is I'd like to hear.

Felix Turner
SimpleViewer Support Team.

Re: Amend the PHP script NOT to overide the captions

Felix, what is the error message?

If you can set up an account for me on your system, I can look directly what is wrong.