Hide /Show a listing in cms builder for property

3 posts by 2 authors in: Forums > CMS Builder
Last Post: September 16, 2013   (RSS)

By Jason - September 16, 2013

Hi

So it looks like you have a checkbox called "hide_listing" and you want to not return any records with that checked.  Is that right?

If so, you can put in a where clause to your getRecords() call like this:

// load records from 'listings'
list($listingsRecords, $listingsMetaData) = getRecords(array(
'tableName' => 'listings',
'loadUploads' => true,
'allowSearch' => false,
'where'       => "hide_listing != 1",
));


Hope this helps

---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By kitka - September 16, 2013

thx Jason...

it works

jim albert