show if
Hi Ray
I am trying toshow an element based on whether or not 2 entries in the db have content in them. If either has content then the element should be shown. I have tried the below with && and ||. Its fine if there is content in both entries (or no content in each) but the problem arises if there is content in one entry but not the other. At the moment in that instance it hides the element when I am trying to show it.
<?php if ("".($Slideshow->getColumnVal("SlideshowTitle") ."" != "") && ($Slideshow->getColumnVal("SlideshowContent") ."" != "")) { ?><div class="ms-layer ms-caption" style="width: 240px; height: 268px; top:0; right:0; background: #b3a895; color: #fff; text-align:center; padding: 0 20px;">
<h2 style="color:#fff;"><?php echo($Slideshow->getColumnVal("SlideshowTitle")); ?></h2>
<p style="color: #fff; font-style:italic;"><?php echo($Slideshow->getColumnVal("SlideshowContent")); ?></p>
</div><?php } ?>
thanks
Jamie