Support » Plugins » [Plugin: Live Comment Preview] Text only displaying when logged in

  • Hello all,

    I’ll keep this as short as possible. I’ve been using live comment preview on my site for a few months now but when I created a new theme, using HTML5 elements, the comment preview stopped working. I don’t think it’s anything I’ve done as I haven’t changed the code I was using when it was working previously.

    One thing I cannont get my head around is the fact that the comment preview works perfectly when I’m logged in and posting a comment through the form as usual. But as soon as I log out the preview stops working. I’ve tried fiddling about with a few parts of the plugin and my own comments.php file but I’m not that great at php and don’t really know if what I’m doing is correct, it’s all a bit hit and miss.

    Hopefully someone out there will have had the same problem as me or will know how to fix it.

    <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 wp_logout_url(); ?>" title="Log out of this account">Log out &raquo;</a></p>
    <?php else : ?>
        <h3>Allowed XHTML</h3>
        <p><?php echo allowed_tags(); ?></p>
        <p>Line breaks and paragraphs are automatically generated.</p>
        <p>Off-topic or inappropriate comments will be edited or deleted.</p>
                <h3>Your Details</h3>
                <label for="author">Name <?php if ($req) echo "(required)"; ?></label>
                <input type="text" name="author" id="author" value="<?php echo $comment_author; ?>" size="22" tabindex="1" <?php if ($req) echo "aria-required='true'"; ?> />
                <label for="email">E-Mail (not published) <?php if ($req) echo "(required)"; ?></label>
                <input type="text" name="email" id="email" value="<?php echo $comment_author_email; ?>" size="22" tabindex="2" <?php if ($req) echo "aria-required='true'"; ?> />
                <label for="url">Website</label>
                <input type="text" name="url" id="url" value="<?php echo $comment_author_url; ?>" size="22" tabindex="3" />
                <?php endif; ?>
            <h3>Post Your Views On The Subject</h3>
            <textarea name="comment" id="comment" cols="45" rows="10" tabindex="4"></textarea>    
            <input name="submit" type="submit" id="submit" tabindex="5" value="Submit Comment" />
            <input type="hidden" name="comment_post_ID" value="<?php echo $id; ?>" />
    <section id="form-extras">
        <h3>Follow Comments</h3>
        <?php show_subscription_checkbox(); ?>
        <h3>Comment Preview</h3>
        	<?php do_action('comment_form', $post->ID); ?>

    I’ve firebugged the live comment preview section and it’s just showing the commentPreview div as empty.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Is anyone able to help? Was up last night trying to solve this but I’m not any further on.

    I’m still not closer to figuring out this problem, is anyone able to help?

    I’ve emailed the plugin developer but I’ve recieved no response from him either.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Plugin: Live Comment Preview] Text only displaying when logged in’ is closed to new replies.