Home | Products | Consulting | Forums | Support | Order | 1-800-752-0455
  Main
Index
Search
Posts
Who's
Online
Log
In

Home: Products: CMS Builder:
Displaying Upload Field Data

 

 


DHester
User

Apr 4, 2008, 9:10 PM

Post #1 of 3 (278 views)
Shortcut
Displaying Upload Field Data Can't Post

I'm creating a blog/news section on my site using CMS Builder. With each post, the user will have an option to create a gallery of related images using the 'upload' field type. Works great but I need to add some conditional logic:

If record exists and the 'Gallery' upload field has at least 1 photo in it then:

Display a custom CSS div with all the images inside

Else:

Don't show any CSS div for the gallery / Don't show any images.



Make sense? Right now my code displays a empty gallery box if no images are in the upload field. I'd prefer not to show anything at all ( no gallery box ).

I need to check if 'gallery' contains any items before the foreach is executed to display the items:

<?php foreach (getUploads($options['tableName'], 'gallery', $record['num']) as $upload): ?>

Can someone point me in the right direction?

Thanks Wink

Darren Hester
www.designsbydarren.com

(This post was edited by DHester on Apr 4, 2008, 9:12 PM)


DHester
User

Apr 5, 2008, 7:28 PM

Post #2 of 3 (251 views)
Shortcut
Re: [DHester] Displaying Upload Field Data [In reply to] Can't Post

For those looking for a solution to this, I found the answer I need here:

http://www.interactivetools.com/iforum/gforum.cgi?post=59803

It worked great!

Darren Hester
www.designsbydarren.com


Dave
Staff / Moderator


Apr 5, 2008, 10:00 PM

Post #3 of 3 (243 views)
Shortcut
Re: [DHester] Displaying Upload Field Data [In reply to] Can't Post

Glad you figured it out and thanks for posting the link for others! I'll get your next question! :)

Dave Edis - Senior Developer
interactivetools.com

 
 
 


Search for (options)
Products
CMS Builder
Article Manager
Realty Manager
Listings Manager
Order Now
Services
Priority Consulting
Support
Online Documentation
Support Forums
Support Homepage
Company Info
12 reasons to choose us!
Meet the team
Monthly newsletter
Contact Us
Toll Free: 1-800-752-0455
Phone: (604) 689-3347
Sales | Support
Conditions of Use | Privacy Policy | Copyright © interactivetools.com 2008
#201 - 2730 Commercial Drive, Vancouver BC Canada V5N 5P4