Double comments box on our blog
-
look in your single.php, see if there’s two tags for the comment form.
deepbevel,
First, thanks for the response.
Could you give me an example of what the tag for the comment form would look like?
I just want to make sure what I need to look for and/or change. I don’t want to crash the site again.
Thanks,
-David
<?php comments_template(); ?>
deepbevel, and everyone else
I took a look in our single.php and I did not find a tag that exactly matches the one deepbevel suggested that I look for.
I found two that are similar, but they don’t match exactly. I will now show the two tags I did find. They are:
<?php if (in_category($blog_include)) { comments_template('', true); } ?>
And the other is:
<?php $withcomments = "1"; comments_template(); ?>
For completeness I’ll list the whole single.php in case there is something I missed:
<?php get_header();?> <!-- BEGIN OF PAGE TITLE --> <?php $blog_cats_include = get_option('vulcan_blog_cats_include'); $team_cat = get_option('vulcan_team_cid'); $client_cat = get_option('vulcan_client_cid'); ?> <?php if (have_posts()) : ?> <div id="page-title"> <div id="page-title-inner"> <div class="title"> <h1> <?php if(is_array($blog_cats_include)) { $blog_include = implode(",",$blog_cats_include); } $porto_cat = get_option('vulcan_portfolio_cid'); if (in_category($blog_include)) { echo __('Disability Determination Services','vulcan'); } else if (in_category($team_cat)) { echo __('Disability Determination Services','vulcan'); } else if (in_category($client_cat)) { echo __('Disability Determination Services','vulcan'); } ?> </h1> </div> </div> </div> <!-- END OF PAGE TITLE --> <!-- BEGIN OF CONTENT --> <div id="content"> <div id="content-left"> <div class="maincontent"> <?php while (have_posts()) : the_post(); $video_image_link = get_post_meta($post->ID, '_video_image_link', true ); $thumb_image = get_post_meta($post->ID, '_thumb_image', true ); ?> <!-- begin of blog post --> <?php if (in_category($blog_include)) : ?> <div class="left-head"> <div class="date"><?php the_time('d');?></div> <div class="month"><?php the_time('M');?></div> </div> <?php endif;?> <div class="right-head"> <h3><?php the_title();?></h3> <?php if (in_category($blog_include)) : ?> <div class="post-info"><?php echo __('posted by ','vulcan');?>: <?php the_author_posts_link();?> | category : <?php the_category(',');?> | <?php echo __('comments ','vulcan');?>: <?php comments_popup_link(__('0 Comment','vulcan'),__('1 Comment','vulcan'),__('% Comments','vulcan'));?></div> <?php endif; ?> </div> <div class="blog-posted"> <?php if (in_category($blog_include)) { if ($video_image_link) { if (is_youtube($video_image_link)) { ?> <div class="movie_container"><a>" rel="youtube"></a></div> <?php } else if (is_vimeo($video_image_link)) { ?> <div class="movie_container"><a>" rel="vimeo"></a></div> <?php } else if (is_quicktime($video_image_link)) { ?> <div class="movie_container"><a>" rel="quicktime"></a></div> <?php } else if (is_flash($video_image_link)) { ?> <div class="movie_container"><a>" rel="flash"></a></div> <?php } } else { ?> <div class="blog-box"> <?php if (function_exists('has_post_thumbnail') && has_post_thumbnail()) {?> <img src="<?php bloginfo('template_directory');?>/timthumb.php?src=<?php echo thumb_url();?>&h=129&w=223&zc=1" alt=""/> <?php } else { if ($thumb_image) { ?> <img src="<?php bloginfo('template_directory');?>/timthumb.php?src=<?php echo $thumb_image;?>&h=129&w=223&zc=1" alt=""/> <?php } } ?> </div> <?php } } else if (in_category($team_cat)) { ?> <?php if (function_exists('has_post_thumbnail') && has_post_thumbnail()) {?> <img src="<?php bloginfo('template_directory');?>/timthumb.php?src=<?php echo thumb_url();?>&h=60&w=60&zc=1" alt="" class="imgleft border" /> <?php } else { if ($thumb_image) { ?> <img src="<?php bloginfo('template_directory');?>/timthumb.php?src=<?php echo $thumb_image;?>&h=60&w=60&zc=1" alt="" class="imgleft border" /> <?php } } ?> <?php } else if (in_category($client_cat)) { ?> <?php if (function_exists('has_post_thumbnail') && has_post_thumbnail()) {?> <img src="<?php bloginfo('template_directory');?>/timthumb.php?src=<?php echo thumb_url();?>&h=60&w=60&zc=1" alt="" class="imgleft border" /> <?php } else { if ($thumb_image) { ?> <img src="<?php bloginfo('template_directory');?>/timthumb.php?src=<?php echo $thumb_image;?>&h=60&w=60&zc=1" alt="" class="imgleft border" /> <?php } } } ?> <?php the_content();?> <div class="clr"></div> <?php $disable_authorbox = get_option('vulcan_disable_authorbox'); if ($disable_authorbox == false) : ?> <div class="author"> <?php if (function_exists('get_avatar')) { echo get_avatar(get_the_author_meta('user_email'), '70'); } else {?> <img src="<?php bloginfo('template_directory');?>/images/author.jpg" alt="" class="imgleft authorpic" /> <?php } ?> <h5>About <?php the_author();?></h5> <?php the_author_meta('description'); ?> </div> <?php endif; ?> <div class="clr"></div> <?php if (in_category($blog_include)) { comments_template('', true); } ?> <?php $withcomments = "1"; comments_template(); ?> </div> <?php endwhile;?> </div> </div> <?php endif;?> <?php get_sidebar();?> </div> <!-- END OF CONTENT --> <?php get_footer();?>
These are the only two lines of code in the single.php that resemble a tag for the comments form.
Could having both of these lines of code in our single.php be causing our blog to have a double comments box?
And if these lines of code aren’t causing the double comments box, what template or theme file should I look in next?
Thanks for trying to help a WordPress Novice.
-David
I’ve not seen a single.php template like this, is this a premium theme? If so it’s going to be difficult to work with.
This forum gives support for open source themes.Have you tried to contact the theme author?
I believe that this is a custom theme that a marketing firm built for our company before I was employed here.
Do you recommend that I take my question into a different forum?
Should I go to the person, or persons that built our template?
Thanks again.
-David
Should I go to the person, or persons that built our template?
That would be your best course of action, yes.
- The topic ‘Double comments box on our blog’ is closed to new replies.
(@david-a-gomez)
11 years, 6 months ago
Hello,
Maybe if I do my best to describe my problem it will make it easier for the community to help me. So here it goes.
The problem we are having is that the blog section on our website has a double comments box.
What I mean is that quite literally, we have one comments box stacked on top of another.
Keep in mind that our blog is merely part of our website, and the blog is not a blog site that stands alone.
So you go to our homepage:
http://www.unival-med.com/
And then from our menu at the top you’d click the purple link that says “blog”.
It then takes you to our blog page where the blog posts are listed by date. There is only one post there because we’ve avoided using the blog until we can fix the double comments issue:
http://www.unival-med.com/?page_id=1546
When you click the “Read More” button under the blog post it takes you to the post where you can see it has a double comments box.
Take a look:
http://www.unival-med.com/?p=1168
Now I’m pretty sure it’s a coding issue within one of the theme templates, but I checked the most likely areas and I couldn’t solve the double comments box issue.
I tried looking at the admin/theme-options.php:
And the functions.php:
The only thing that improved the looks of our blog was when I went in and messed with the actual comments.php:
I deleted the comments.php and ALL of the comments boxes went away. I would like for it to just have one comments box though.
Does anyone have an idea what could cause this problem? Or does anyone at least know where I can look to try and change the coding to get the one comments box look I’m after?
Keep in mind I didn’t build this site, I was just given the job of managing the site and I’m trying to piece together the site’s WordPress history via old emails. I’d have built the site differently if it were my project from the beginning.
Any help you could give me would be much appreciated. I am not a WordPress or coding expert, but I’d really like to impress by boss by fixing this issue.
Thanks again,
-David