Skip to content

Instantly share code, notes, and snippets.

@sameronline
Created May 3, 2012 21:27
Show Gist options
  • Save sameronline/2589656 to your computer and use it in GitHub Desktop.
Save sameronline/2589656 to your computer and use it in GitHub Desktop.
page comment
<?php if($node->comment == 2 OR $comments){ ?>
<div id="comments" class="section comments">
<?php if($node->comment == 2){ ?>
<h3>
<?php
if ($node->type == 'baby_name'):
$default_title = t('What do you think about the name !s ?', array('!s' => $node->title));
else:
$default_title = t('What do you think?');
endif;
echo theme('comment_form_title', $node->field_comment_form_title, $default_title);
?>
</h3>
<?php echo drupal_get_form('comment_form', array('nid' => $node->nid), ''); ?>
<?php } ?>
<?php if($comments) {
echo $comments;
} ?>
</div>
<?php } ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment