Displaying Record Uploads and Descriptions Horizontally

2 posts by 2 authors in: Forums > CMS Builder
Last Post: May 6, 2009   (RSS)

By Cathy - May 5, 2009

I am try to display the uploads for records, in the individual record page, horizontally. These will be pictures with a description - I will be displaying the thumbnails with a click for larger image.

I tried to implement the code I found in some other posts, but obviously I am not doing something correctly.

Here is the code I have to currently display the uploads:

<table width="500" border="0" cellspacing="3" cellpadding="0">
<tr>
<?php foreach ($eventsRecord['images'] as $upload): ?>
<?php if ($upload['hasThumbnail']): ?>
<td width="165" align="center">
<a href="<?php echo $upload['urlPath'] ?>" rel="facebox"><img src="<?php echo $upload['thumbUrlPath'] ?>" alt="" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" border="1" /></a><br />
<?php echo $upload['info1'] ?><br />
<?php echo $upload['info2'] ?> </td>
<?php elseif ($upload['isImage']): ?>
<td width="165" align="center"><img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br />
<?php echo $upload['info1'] ?><br />
<?php echo $upload['info2'] ?></td>
<?php else: ?>
<td width="165"><a href="<?php echo $upload['urlPath'] ?>"> Download <?php echo $upload['filename'] ?></a></td>
<?php $maxCols=3; if (@++$count % $maxCols == 0): ?>
<?php endif ?>
<?php endforeach ?>
</tr>
</table>


The error I get displayed is:
Parse error: syntax error, unexpected T_ENDFOREACH in /home/content/s/p/e/spectrumlight/html/events.php on line 95

The page can be viewed here:
http://spectrumlightco.com/events.php?POW-Breast-Cancer-Awareness-Event-2

I am trying to display 3 images across with the description for each below the image in the same table cell.

Any suggestions?

Thanks!

Cathy
__________________________________
Grafix Unlimited