Checked list field displays an image - how to?

13 posts by 2 authors in: Forums > CMS Builder
Last Post: May 14, 2012   (RSS)

By csdesign - May 14, 2012

Hi Jerry,
I'm not frustrated... I realize there can be a process to things :)

I made dummys for each:

http://www.dunhamrealestateservices.com/listingDetail1.php?Condo-for-Sale-in-Red-Lodge-MT-38

http://www.dunhamrealestateservices.com/listings1.php?property_type=Residential

The listingDetail page seems to be working perfect. The new banner is showing and it's only on the one property that it's supposed to be on.

It's the listings.php page that's showing both text and image on every single property even though that "condo for sale in red lodge, MT" is the only one marked "new".

Thanks a ton!! Files are attached.
Attachments:

listings1.php 8K

By csdesign - May 14, 2012 - edited: May 14, 2012

Thanks Jerry! Looks like we were just circling the wagons! It's working now.

I had to remove the last line to get rid of the text repeat of the word "new". Working great with this code below. I also tested another property, marking it "reduced" and that came up on the list page too, just like it was supposed to. :)

Thanks SO much for your help!! Tina


<?php if ($listing['banner_status'] == 'Sold') : ?><img src="http://www.dunhamrealestateservices.com/images/bnr-sold.jpg" width="312" height="25" /><?PHP endif ?>
<?php if ($listing['banner_status'] == 'Reduced') : ?><img src="http://www.dunhamrealestateservices.com/images/bnr-reduced.jpg" width="312" height="25" /><?PHP endif ?>
<?php if ($listing['banner_status'] == 'New') : ?><img src="http://www.dunhamrealestateservices.com/images/bnr-new-listing.jpg" width="312" height="25" /><?PHP endif ?>


Removing all the status banners now because that property wasn't actually "new" so they won't be showing at all on the site - but they work! thanks again!