Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Instead of clicking reply on my comments I have them laid out with a reply form already showing underneath each comment.

Each form has been populated with the post_id and the comment_id and looks like...

<div id="respond">
        <form action="<?php bloginfo('url'); ?>/wp-comments-post.php" method="post" id="commentform">
            <div class="comment-content standard-form">
                <p class="form-textarea ">
                    <textarea name="comment" id="comment" rows="5" aria-required="true"></textarea>
                <p class="form-submit">
            <input name="submit" type="submit" id="submit" value="Send" />
            <input type='hidden' name='comment_post_ID' value='<?php the_id(); ?>' id='comment_post_ID' />
            <input type='hidden' name='comment_parent' id='comment_parent' value='<?php comment_id(); ?>' />
                <p style="display: none;">
                    <input type="hidden" id="akismet_comment_nonce" name="akismet_comment_nonce" value="y3b1b72u3o" />
            </div><!-- .comment-content standard-form -->

This displays fine, but if I fill in a comment and hit submit I get the following error message

ERROR: please type a comment.

Is there something wrong with my form or can anyone tell me why its happening?

share|improve this question
You will need some kind of unique identifier on the forms and elements. Having more then one of these will give you multiple duplicates of the variables you want. You can easily check what gets forwarded to the php-script by changing the url to anything and the method to get instead of post. –  Hoshts Apr 13 '13 at 16:02
It doesn't matter how often you use an ID, see this testfile. –  Ralf912 May 3 '13 at 2:47
Is the ERROR: please type a comment. an JavaScript alert box? It seems there is a JavaScript that validate the comment form and catch the first it can find in your DOM. You have to deactivate the JS and apply an unique number to each ID in the form elements. Not required, but the better way. –  Ralf912 May 3 '13 at 2:50
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.