I'm using the theme 'Deep Red', and I'm having comment issues.
1. The name of the author appears in white, the same colour as my background, and I can't find anyplace to change this in the CSS.
2. When I post a new comment, all of the deleted comments reappear, and instead of saying (for example) 'One Response to “Test Post”', it says 'No Responses to “”'.
3. After I post a comment, this style uses an AJAX comment system, it says something in Spanish. I also cannot find any way to change this.
I will now post up the codes of some pages to help.
/wp-content/themes/deep-red/style.css
/*
Theme Name: Deep Red
Theme URI: http://templates.arcsin.se/
Version: 1.0
Description: A two-column layout with a touch of red. Based on the <a href="http://templates.arcsin.se/deep-red-website-template/">Deep Red website template</a>.
Author: Viktor Persson
Author URI: http://arcsin.se/
Last updated: 2009-05-27
*/
/* standard elements */
* {
margin: 0;
padding: 0;
}
body {
background: #6C1400 url(img/bgbody.gif) repeat-y center top;
font: normal 0.7em Tahoma,Verdana,sans-serif;
}
div a {
color: #FFF;
cursor: pointer;
text-decoration: none;
}
h1 {
color: #444;
font: normal 2em sans-serif;
margin: 18px 0 0 0;
}
code {
background: url(img/bgcode.gif);
border: 1px solid #F0F0F0;
border-left: 6px solid #D91623;
color: #555;
display: block;
font: normal 1em "Lucida Sans Unicode",serif;
margin-bottom: 12px;
padding: 8px 10px;
white-space: pre;
}
blockquote {
background: url(img/quote.gif) no-repeat;
color: #555;
display: block;
font: bold 1.2em "Trebuchet MS",serif;
margin: 6px 0;
padding-left: 28px;
}
/* structure */
.main {
width: 680px;
margin: 0 auto;
}
.main_left {
float: left;
padding-top: 6px;
width: 420px;
}
.main_right {
border-top: 6px solid #FFF;
float: right;
width: 254px;
}
.footer {clear: both;}
/* misc */
.left {
float: left;
}
.right {
float: right;
}
.clearer {
clear: both;
font-size: 0;
line-height: 0;
display: block;
}
.header,.link_projects,.lbl,.link_updates a {
border-bottom: 6px solid #FFF;
}
div.link_projects a:hover,div.link_updates a:hover, .content a:hover, div.footer div.left a:hover {
background: #D7162C;
color: #FFF;
}
div.link_subpages {background: #222 url(img/grdnt_gray.gif) repeat-x;}
div.link_subpages li {list-style: none; border-bottom: 5px solid #FFF;}
div.link_subpages a {
display: block;
padding: 15px 5%;
width: 90%;
font-weight: bold;
}
div.link_subpages a:hover {
background: #D7162C;
color: #FFF;
}
/* logo */
.header {
background: #D91623 url(img/bgheader.png) repeat-x;
height: 180px;
}
.header h1 {
margin: 0;
padding: 124px 0 0 24px;
font: normal 2.2em Verdana,sans-serif;
display: none;
}
/* main navigation */
.link_menu {
background: #CC2224 url(img/grdnt_red.png) repeat-x;
}
.link_menu a {
border-bottom: 1px solid #FFF;
display: block;
font: bold 0.9em Verdana,sans-serif;
height: 18px;
padding: 6px 0 0 10px;
text-decoration: none;
}
.link_menu a:hover {background: #444;}
#navMenu li {
list-style-type:none;
}
/* projects */
.lbl {
background: #222 url(img/bglbl.gif) repeat-x;
clear: both;
color: #FFF;
font: normal 2em "Lucida Sans Unicode",sans-serif;
height: 50px;
line-height: 50px;
overflow: hidden;
text-align: center;
}
.link_projects a {
display: block;
height: 100px;
text-align: center;
color: #FFF;
padding-top: 24px;
width: 124px;
font-size: 0.9em;
font-family: sans-serif;
}
.link_projects a span {
font: normal 5em sans-serif;
}
a.g1 {
background: #888;
}
a.g2 {
background: #666;
border-left: 6px solid #FFF;
}
/* updates */
.link_updates {
background: #222 url(img/grdnt_gray.gif) repeat-x;
}
.link_updates .lbl {
height: 100px;
line-height: 100px;
}
.link_updates a {
clear: right;
display: block;
font: normal 1em "Trebuchet MS",sans-serif;
height: 55px;
padding: 10px 0;
text-align: center;
}
.link_updates a span {
float: left;
font: bold 1.1em Verdana,sans-serif;
margin-left: 6px;
margin-top: 14px;
padding: 5px;
}
/* content */
.content {
color: #444;
font-family: Verdana,sans-serif;
line-height: 1.3em;
padding: 0 10px 10px;
}
.content a {
color: #FD1C24;
}
.content p {
margin: 4px 0 10px 0;
}
.content .descr {
color: #666;
margin-bottom: 6px;
}
.content li {
list-style: url(img/li.gif);
margin-left: 18px;
}
/* footer */
.footer {
color: #666;
clear: both;
}
.footer .right a {
background: #2A2A2A;
color: #555;
padding: 1px 3px;
}
.footer .right a:hover {
background: #383838;
color: #999;
}
.footer .left a {
color: #777;
}
.footer .left {
border-top: 1px solid #F0F0F0;
padding: 9px 0 9px 9px;
width: 407px;
}
.footer .right {
margin-right: 8px;
padding: 9px 0;
text-align: right;
width: 220px;
}
/* COMMENTS */
.commentlist li {
background: url(img/bgcode.gif);
border: 1px solid #F0F0F0;
border-left: 6px solid #D91623;
color: #555;
display: block;
font: normal 1em "Lucida Sans Unicode",serif;
margin-bottom: 12px;
padding: 8px 10px;
}
.commentmetadata a, #commentform a {
color:#D91623;
}
#comment {
width:97%;
height:15em;
}
.insertando {
text-align:center;
font-size:1.5em;
}
.gravatar {
float:right;
}
/* Widgets */
.widge ul {
padding: 12px;
background: #
}
.widget ul {background: #222 url(img/grdnt_gray.gif) repeat-x;}
.widget ul li {list-style: none; border-bottom: 5px solid #FFF;}
.widget ul a {
display: block;
padding: 15px 5%;
width: 90%;
font-weight: bold;
}
.widget ul a:hover {
background: #D7162C;
color: #FFF;
}
.widget form {color: #AAA; padding: 12px;}
/wp-content/themes/deep-red/comments.php
<?php // Do not delete these lines
if ('comments.php' == basename($_SERVER['SCRIPT_FILENAME']))
die ('Please do not load this page directly. Thanks!');
if (!empty($post->post_password)) { // if there's a password
if ($_COOKIE['wp-postpass_' . COOKIEHASH] != $post->post_password) { // and it doesn't match the cookie
?>
<p class="nocomments">This post is password protected. Enter the password to view comments.<p>
<?php
return;
}
}
/* This variable is for alternating comment background */
$oddcomment = 'alt';
?>
<!-- You can start editing here. -->
<div id="ajax_comments">
<?php if ($comments) : ?>
<h3 id="comments"><?php comments_number('No Responses', 'One Response', '% Responses' );?> to “<?php the_title(); ?>”</h3>
<ol class="commentlist">
<?php foreach ($comments as $comment) : ?>
<li id="comment-<?php comment_ID() ?>">
<?php if (function_exists('gravatar')) { ?><img src="<?php gravatar("X", 32, ""); ?>" class="gravatar" alt="Gravatar Icon" /><?php } ?>
<cite><?php comment_author_link() ?></cite> Says:
<?php if ($comment->comment_approved == '0') : ?>
<em>Your comment is awaiting moderation.</em>
<?php endif; ?>
<br />
<small class="commentmetadata"><a href="#comment-<?php comment_ID() ?>" title=""><?php comment_date('F jS, Y') ?> at <?php comment_time() ?></a> <?php edit_comment_link('e','',''); ?></small>
<?php comment_text() ?>
</li>
<?php /* Changes every other comment to a different class */
if ('alt' == $oddcomment) $oddcomment = '';
else $oddcomment = 'alt';
?>
<?php endforeach; /* end for each comment */ ?>
</ol>
<?php else : // this is displayed if there are no comments so far ?>
<?php if ('open' == $post->comment_status) : ?>
<!-- If comments are open, but there are no comments. -->
<?php else : // comments are closed ?>
<!-- If comments are closed. -->
<p class="nocomments">Comments are closed.</p>
<?php endif; ?>
<?php endif; ?>
</div>
<?php if ('open' == $post->comment_status) : ?>
<h3 id="respond">Leave a Reply</h3>
<?php if ( get_option('comment_registration') && !$user_ID ) : ?>
<p>You must be <a href="<?php echo get_option('siteurl'); ?>/wp-login.php?redirect_to=<?php the_permalink(); ?>">logged in</a> to post a comment.</p>
<?php else : ?>
<form action="<?php echo get_option('siteurl'); ?>/wp-comments-post.php" method="post" id="commentform">
<?php if ( $user_ID ) : ?>
<p>Logged in as <a href="<?php echo get_option('siteurl'); ?>/wp-admin/profile.php"><?php echo $user_identity; ?></a>. <a href="<?php echo get_option('siteurl'); ?>/wp-login.php?action=logout" title="Log out of this account">Logout »</a></p>
<input type="hidden" name="author" id="author" value="<?php echo $comment_author; ?>" size="22" tabindex="1" />
<input type="hidden" name="email" id="email" value="<?php echo $comment_author_email; ?>" size="22" tabindex="2" />
<input type="hidden" name="url" id="url" value="<?php echo $comment_author_url; ?>" size="22" tabindex="3" />
<?php else : ?>
<p><input type="text" name="author" id="author" value="<?php echo $comment_author; ?>" size="22" tabindex="1" />
<label for="author"><small>Name <?php if ($req) echo "(required)"; ?></small></label></p>
<p><input type="text" name="email" id="email" value="<?php echo $comment_author_email; ?>" size="22" tabindex="2" />
<label for="email"><small>Mail (will not be published) <?php if ($req) echo "(required)"; ?></small></label></p>
<p><input type="text" name="url" id="url" value="<?php echo $comment_author_url; ?>" size="22" tabindex="3" />
<label for="url"><small>Website</small></label></p>
<?php endif; ?>
<!--<p><small><strong>XHTML:</strong> You can use these tags: <?php echo allowed_tags(); ?></small></p>-->
<p><textarea name="comment" id="comment" tabindex="4"></textarea></p>
<p><input name="submit" type="submit" id="submit" tabindex="5" value="Submit Comment" />
<input type="hidden" name="comment_post_ID" value="<?php echo $id; ?>" />
</p>
<?php do_action('comment_form', $post->ID); ?>
</form>
<?php endif; // If registration required and not logged in ?>
<?php endif; // if you delete this the sky will fall on your head ?>
<script type="text/javascript" src="<?php bloginfo('template_directory'); ?>/js/k2functions.js"></script>
/wp-content/themes/deep-red/php/comments_ajax.php
<?
if ($_POST['comment_post_ID'])
{
require( '../../../../wp-config.php' );
global $userdata;
get_currentuserinfo();
$comment_post_ID = (int) $_POST['comment_post_ID'];
$status= $wpdb->get_row("SELECT post_status, comment_status FROM $wpdb->posts WHERE ID = '".$_POST['comment_post_ID']."'");
$commentCount = 1;
}
/* This variable is for alternating comment background */
$oddcomment = 'alt';
$comments = $wpdb->get_results("SELECT * FROM $wpdb->comments WHERE comment_post_ID = '".$_POST['comment_post_ID']."' ORDER BY comment_date");
$oddcomment = 'alt';
if ($comments) : ?>
<h3 id="comments"><?php comments_number('No Responses', 'One Response', '% Responses' );?> to “<?php the_title(); ?>”</h3>
<ol class="commentlist">
<?php foreach ($comments as $comment) : ?>
<li id="comment-<?php comment_ID() ?>">
<cite><?php comment_author_link() ?></cite> Says:
<?php if ($comment->comment_approved == '0') : ?>
<em>Your comment is awaiting moderation.</em>
<?php endif; ?>
<br />
<small class="commentmetadata"><a href="#comment-<?php comment_ID() ?>" title=""><?php comment_date('F jS, Y') ?> at <?php comment_time() ?></a> <?php edit_comment_link('e','',''); ?></small>
<?php comment_text() ?>
</li>
<?php /* Changes every other comment to a different class */
if ('alt' == $oddcomment) $oddcomment = '';
else $oddcomment = 'alt';
?>
<?php endforeach; /* end for each comment */ ?>
</ol>
<?php else : // this is displayed if there are no comments so far ?>
<?php if ('open' == $post->comment_status) : ?>
<!-- If comments are open, but there are no comments. -->
<?php else : // comments are closed ?>
<!-- If comments are closed. -->
<p class="nocomments">Comments are closed.</p>
<?php endif; ?>
<?php endif; ?>
</div>
</div>