• Resolved guitarcrazy087

    (@guitarcrazy087)


    Okay so here’s my site if you’d like to see the glitch first hand:

    https://joehenry.frihost.net

    On the “About” PAGE I have the comments enabled and working. The glitch is that after you fill out the form and submit the comment you get a 404 Not Found error. But then if you go back to the About page and refresh, your comment still shows up none-the-less.

    Any ideas about what’s wrong are appreciated.

    Here’s my page.php code:

    <?php get_header(); ?>
    
    <?php if (have_posts()) : while (have_posts()) : the_post();
    	$date = $post->post_date;
    	$date = my_date_format($date);
    ?>
    
    <div class="sectionheader" id="post-<?php the_ID(); ?>"><a name="entry"></a>
    	<div class="title"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></div>
    	<div class="commentsnum right"><a href="#comments"><?php comments_number(__('No Comments'), __('1 Comment'), __('% Comments')); ?></a></div>
    	<div class="date"><?php echo $date; ?></div>
    </div>
    
    <div class="entry">
    <?php wp_link_pages(array('before' => '<p><small><strong>Pages:</strong> ', 'after' => '</small></p>', 'next_or_number' => 'number')); ?>
    <?php the_content('<p class="right">Read the rest of this page &raquo;</p>'); ?>
    <?php wp_link_pages(array('before' => '<p><small><strong>Pages:</strong> ', 'after' => '</small></p>', 'next_or_number' => 'number')); ?>
    </div>
    
    <hr />
    
    <p class="postmetadata"><small>
    	<?php edit_post_link('Edit this entry &raquo;', '<p>', '</p>'); ?>
    	<p>This page was posted on <?php the_time('l, F jS, Y') ?> at <?php the_time() ?>.</p>
    <?php if ('open' == $post-> comment_status) { ?>	<p><a href="#comments">Leave a comment.</a></p><?php } else { ?>	<p>Comments are currently closed.</p><?php } ?>
    
    </small></p>
    
    <?php
    comments_template();
    endwhile;
    endif; 
    
    get_footer();
    ?>

    I’m pretty sure that it’s not something in my comments.php code because the comments work fine on the post pages.

    Thanks in advance and again, any help is really appreciated!

    Joe

Viewing 6 replies - 1 through 6 (of 6 total)
  • I’m not convinced that comments will work in a WordPress page (as opposed to a Post).

    Thread Starter guitarcrazy087

    (@guitarcrazy087)

    Hey I got it fixed. Thanks though.

    Hey guitarcrazy087,
    could you post the solution. I’m having the same issue.
    Thanks.

    Hey guitarcrazy087,
    could you post the solution. I’m having the same issue.
    Thanks.

    Ditto. Please tell us the solution guitarcrazy087! I’m having the same problem with a clean WMPU 2.7.1 install with comments on pages on subdomain blogs using the default (kubrick) theme.

    After playing around I’ve found out that the problem isn’t quite what I thought it was. Basically I had set the auto-generated “about” page of a new blog to be the “homepage” in Settings-Reading. It’s when you try to comment on a page that is set as the homepage that this problem occurs, because the page is being displayed without its “proper” URL. Therefore, the comment gets saved to the database but the redirect goes awry.

    I’m off to google the new problem becaus I think I saw this come up on my previous searches. Hope that helps someone.

    roberthq

    (@roberthqprintsnet)

    Yeah, that would be helpful to share what you did rather than doing nothing. Kind of defeats the purpose of this forum.

    I also had the same problem, but it was on Posts.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘404 Not Found Error with Comments on Page’ is closed to new replies.