Hi Dave.
I seem to be having a problem with my XML gallery with the CMS and I believe I narrowed it down. My XML is looking for a URL, while the CMS referencing the file path in the file system. How do I correct for this?
I changed the upload field directory to the folder where I originally put my photos to test the gallery. (If I switch my XML to read just the file name, I can view the gallery just fine.) Is it possible to modify the php so it just reads the file name? And in regards to the caption, what should I do? I'm experiencing the same problem with the caption URL vs. file path.
Here's a sample of my xml code:
<?php echo('<?xml version="1.0" encoding="utf-8"?>'); ?>
<?php
require_once "/data/home/riverschoolboats/websites/riverschoolboats.com/docs/cms/lib/viewer_functions.php";
list($artistRecords, $artistMetaData) = getRecords(array(
'tableName' => 'artist',
'where' => whereRecordNumberInUrl(1),
'limit' => '1',
));
$artistRecord = @$artistRecords[0];
?>
<config>
<baseurl>/images/</baseurl>
<fadetime>2</fadetime>
<showtime>3</showtime>
<window>_top</window>
<randomorder>true</randomorder>
<texts>true</texts>
<movingtext>true</movingtext>
<mouseover>true</mouseover>
<textposition>2</textposition>
<?php foreach ($artistRecords['uploads'] as $upload): ?>
<image>
<url><?php echo $upload['urlPath']; ?></url>
<caption><?php echo $upload['info1']?>"</caption>
</image>
<?php endforeach; ?>
</config>
Also, if I plan on uploading multiple images to this gallery, do I need to repeat this code to match the desired number of photos per gallery, or will it generate multiple images with this code appearing once?
<image>
<url><?php echo $upload['urlPath']; ?></url>
<caption><?php echo $upload['info1']?>"</caption>
</image>