Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 8149aa43e0
Fetching contributors…

Cannot retrieve contributors at this time

100 lines (76 sloc) 3.513 kb
global $ahimsa_options;
if (!empty($_SERVER['SCRIPT_FILENAME']) &&
'comments.php' == basename($_SERVER['SCRIPT_FILENAME']))
die (__('Please do not load this page directly. Thanks!', 'ahimsa'));
<?php if ( post_password_required() ) : ?>
<p class="nocomments">' .
<?php _e('This post is password protected. Enter the password to view comments.', 'ahimsa'); ?>
<?php return; ?>
<?php endif; ?>
<?php if ( have_comments() ) : ?>
<fieldset id='comments'>
<legend class='title'>
<?php comments_number(
__('No Responses', 'ahimsa'),
__('One Response', 'ahimsa'),
'% ' . __('Responses', 'ahimsa'));?>
The &nbsp; below is to workaround what seems to be a bug in Safari.
Without it, the 'comments' container fieldset (above) is overlapped
by the first comment fieldset.
<?php if( $comments_rss_url = get_post_comments_feed_link() ) : ?>
<div style='float: right; clear: right;' class='capsule actbubble'>
<a href='<?php print $comments_rss_url; ?>'><?php _e('Comments Feed', 'ahimsa'); ?></a>
<?php endif; ?>
<?php if( 'open' == $post->comment_status ) : ?>
<div style='float: right; margin-right: 10px;' class='capsule actbubble'>
<a href='#respond'><?php _e('Add Comment', 'ahimsa'); ?></a>
<?php endif ?>
<?php wp_list_comments('type=all&style=ul&callback=ahimsa_custom_comment'); ?>
<br clear='all' />
<?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : ?>
<div class="postmetadata">
previous_comments_link('<span class="capsule actbubble" style="float: left;">' .
'&laquo; ' . __('previous', 'ahimsa') . '</span>');
next_comments_link('<span class="capsule actbubble" style="float: right;">' .
__('next', 'ahimsa') . ' &raquo;</span>');
<br clear='all'/>
<?php endif; ?>
<?php endif; ?>
if( comments_open() && ! post_password_required()
&& post_type_supports(get_post_type(), 'comments') ) :
// below we use the WP generated reply template form by calling
// the WP function comment_form(). In our JS (currently ahimsa.js)
// this WP generated form is then moved into our responsebox
// fielset below. See relevant comments in ahimsa.js. This is a
// hack but I cannot think of any other way to style the reply form.
<fieldset id='responsebox'>
<legend class='title'><?php _e('Leave a Reply', 'ahimsa'); ?></legend>
<?php if( $ahimsa_options['commentguide'] != "" ) : ?>
<div id='commentguide'>
<?php print stripslashes($ahimsa_options['commentguide']); ?>
<?php endif; ?>
<?php else : ?>
<!-- If comments are closed. -->
<div class='capsule nocomments rounded-big'><?php _e('Comments are closed', 'ahimsa'); ?></div>
<div style='height: 1px; clear: both;'></div>
<?php endif; ?>
Jump to Line
Something went wrong with that request. Please try again.