PDA

View Full Version : Need help with php if statement help for custom page


bzcomputers
02-03-2013, 05:04 AM
Current code:

<div class="blockbox">
<strong><?php echo __('Guest Limit'); ?>:</strong> <span class='hot'><?php echo ($event['Event']['guest_limit']); ?></span>
</div>


This currently outputs: Guest Limit : XX

What I need to change is if the Guest Limit is = "0" I would like it display "No Limit" else display what it currently does.

Lynne
02-03-2013, 05:00 PM
<?php if ($event['Event']['guest_limit'] == 0) $event['Event']['guest_limit']='No Limit'; ?>