"Upload" command - does it allow gallery with linked thumbnails?

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

By meg - June 27, 2008

I'm working on creating a gallery section and I'm using the "upload" field type. Ideally, I'm trying to create a gallery that has thumbnails you can click on to see a larger version on the image. I would also like it to include a title and caption.

In the back-end interface, I can enter a title and caption. However, is this information only for the back-end or can this information show up on the gallery page? Also, I know how to create thumbnails with blank targets for viewing the larger images using wyslwyg but I assumed that the "upload" field type would simplify that and create it using one step - is that true or does it just upload an image to the page using the thumbnail size you specify.

Please help so I can make my gallery! Thank you thank you!
Meg

Re: [meg] "Upload" command - does it allow gallery with linked thumbnails?

By Jake - June 29, 2008

Hi Meg,

Thanks for your post!

The title and caption information for uploads can definitely be used on your public pages - these fields are really useful when setting up image scripts with the software. To use these fields, just add these lines of code in the generated upload code for your image upload field where you'd like them to appear:

<?php echo $upload['title'] ?>

<?php echo $upload['caption'] ?>


By default, this is the code used to generate the image tags for thumbnails:

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


If you want these thumbnails to link to the full-sized version of the image, you can substitute that code with this:

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


I hope this gets helps Meg - let us know if you have any other questions about this. [:)]
-----------------------------------------------------------
Cheers,
Jake Marvin - Product Specialist
support@interactivetools.com

Hire me!
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with Priority Consulting.

Re: [meg] "Upload" command - does it allow gallery with linked thumbnails?

By Donna - June 30, 2008

Hi Meg!

Yep, what it's doing is generating regular HTML, so you can use any sort of HTML that you would normally use. In the "img" tag, feel free to add the target="_blank" and it'll work just fine. :)
Donna

--
support@interactivetools.com