if statement syntax is wrong
Posted: Fri May 20, 2011 1:55 am
Hi,
I am no PHP expert. I can poke about, do a little cut and paste.
Dreamweaver is telling me I have a syntax issue with my if statement. I have tried a few things without success.
Dreamweaver says the error is on the else line, that may not be true. please show me what I am doing wrong.
Thanks Mark
I am no PHP expert. I can poke about, do a little cut and paste.
Dreamweaver is telling me I have a syntax issue with my if statement. I have tried a few things without success.
Dreamweaver says the error is on the else line, that may not be true. please show me what I am doing wrong.
Thanks Mark
Code: Select all
<div class="entry-content tec-event-entry">
<?php /** Get the "cft_tinymce_1" custom field */
$block_1 = get_custom_field('cft_tinymce_1');
if( $block_1 ) { ?>
<?php echo $block_1; ?>
<?php } ?>
<?php else { ?>
<?php the_content(); ?>
<?php } ?>
</div> <!-- End tec-event-entry -->