Re: [sagentic] Making a field only appear if it has data
Cool, thanks that works well. I'm using the below code >
<?php if ($record['store']): ?>View: <?php endif ?>
<?php if ($record['store']): ?><a href="<?php echo $record['store'] ?>" target="_blank">Store Front</a><?php endif ?>
<?php if ($record['auction']): ?><a href="<?php echo $record['auction'] ?>" target="_blank">Auction Template</a><?php endif ?>
Sometimes I may only have the Auction Template link, and with the above code in this form the word "View" wouldn't display if there was only an auction link. How can I edit the code so that it shows "View" if the record is "store" OR "auction"?
Also, if there is more than one link showing, is there anyway to get it to display a comma after each record (except the last one)?
Thanks :)