Getting SQL Erros with relatedlookp code, see thread, Pulling hair out, challenged with viewing data from multiple sections on single viewer page

14 posts by 4 authors in: Forums > CMS Builder
Last Post: March 31, 2010   (RSS)

By Chris - March 30, 2010

Hi Terry,

Glad to help. :)

What do I have to do ensure images pull from the drills database onto the viewer pages for golflessons?


You can copy your existing foreach loop for images, but change the $record variable to $drill:

<?php foreach ($drill['image'] as $upload): ?>
<?php if ($upload['hasThumbnail']): ?>
...snip...
<?php endforeach ?>


Does that work? Please let me know if you have any questions.
All the best,
Chris

Re: [chris] GETTING ERRORS...conflict with membership plugin?Re: [gkornbluth] Pulling hair out, challenged with viewing data from multiple sections on single viewer page

By Codee - March 30, 2010

WOW! Chris ~ THANKS!!!

I appreciate your helping beyond just telling me what to do and I appreciate the learning experience in this...it makes me a better user of CMSB!

Your most recent mods to the plugin and using it (once I came to know a little more) are terrific! The next level of the plugin, maybe making it part of the app store would be is if the section code generator were to take in account the references to other sections and provided the basic output automatically. I'm sure it would save you and your team from answering some of these same questions over and over while making the product even more useful.

Cheers!

Re: [chris] GETTING ERRORS...conflict with membership plugin?Re: [gkornbluth] Pulling hair out, challenged with viewing data from multiple sections on single viewer page

Chris,
Lets say I have two fields that are using the Lookuprelatedfields plugin, how would I code the second field or multiple fields for that matter?

// load referenced records for our fields
beta_lookupRelatedFields(array(
'table' => 'lessons',
'recordList' => &$lessonsRecords,
'fieldList' => array( 'drill','hammer' )

));

Re: [Dan Maitland] GETTING ERRORS...conflict with membership plugin?Re: [gkornbluth] Pulling hair out, challenged with viewing data from multiple sections on single viewer page

By Chris - March 31, 2010

@Dan: Yes, that should do it.

@Terry: I'm hoping to make it easier to use first, possibly by integrating it into getRecords. It's still very much "beta" right now. :)
All the best,
Chris