Why only thumbnails displaying?

2 posts by 2 authors in: Forums > CMS Builder
Last Post: June 30, 2008   (RSS)

By seotech - June 29, 2008

Hi,
On the following page, I have inserted 2 records with photos. They are only displaying as thumbnails even though I have not selected the option to re-size images greater than a certain size. Can you tell me why this is happening?

http://www.qcegoldcoast.qld.edu.au/pages/student.php
Thanks

Re: [seotech] Why only thumbnails displaying?

By Dave - June 30, 2008

Hi seotech, welcome to the CMS Builder forum!

The "Resize images larger than" option resizes images as you upload them. It's the "Create image thumbnails" option that creates the thumbnails.

If you don't want thumbnails just replace this code in your image foreach loop:

<?php if ($upload['hasThumbnail']): ?>
<img src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" alt="" /><br/>

<?php elseif ($upload['isImage']): ?>
<img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br/>

<?php else: ?>
<a href="<?php echo $upload['urlPath'] ?>">Download <?php echo $upload['filename'] ?></a><br/>

<?php endif ?>


With this:

<?php if ($upload['isImage']): ?>
<img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br/>

<?php else: ?>
<a href="<?php echo $upload['urlPath'] ?>">Download <?php echo $upload['filename'] ?></a><br/>

<?php endif ?>


And it won't display the thumbnails.

Hope that helps!
Dave Edis - Senior Developer
interactivetools.com