Getting Post Permalink Outside of Loop Not Working

According to: http://wpseek.com/get_comment_count/ $single is the post ID. Try: public function get_comment_count($single){ if (isset($this->params[‘comments’]) && $this->params[‘comments’] == ‘yes’){ return ‘<div id=”disquscomments”><a href=”‘.get_permalink($single).’#disqus_thread”>Comments</a></div>’; } else { return null; } }

How do I call comments_template(); from a plugin file?

from the wordpress codex: comments_template(); //Loads the comment template. For use in single Post and Page displays. //Will not work outside of single displays unless $withcomments is set to “1”. my bet is that you need that ->$withcomments thingy <?php global $withcomments; $withcomments = true; comments_template(); ?>

edit-comments.php in Admin – how to change ‘Comments’ title?

I think you need to change ‘Comments’ to ‘something’ but it from admin side. Please follow steps: 1> Go to Appearance -> Editor in your WordPress dashboard (In the list of theme files, on the right, click on “Theme Functions” to open your functions.php file) 2> Enter the following code in your functions.php file: add_filter(‘genesis_title_comments’, … Read more

Outputting complete custom comment form

Following was the HTML – <!– Comment Form HTML –> <div class=”sub-figure”> <div class=”sub-post-title”> <h4 class=”recent-title”>Comments</h4> </div> </div> <!– Leave a comment –> <div class=”sub-figure”> <div class=”sub-post-title”> <h4 class=”recent-title”>Leave A Comment</h4> </div> <form class=”form-inline”> <div class=”col-xs-12 col-sm-4 col-md-4 form-group”> <input type=”text” class=”form-control height-in” id=”reply-name” placeholder=”Enter Name”> </div> <div class=”col-xs-12 col-sm-4 col-md-4 form-group”> <input type=”email” class=”form-control … Read more

How do I convert users who put an email and username for a comment into registered users? [duplicate]

To achieve this, create a new page template and use this code in that file. Then, use your submit form to redirect the user after commenting to the new page. $user_login = $_POST[‘user_login’]; $user_email = $_POST[‘user_email’]; $errors = register_new_user($user_login, $user_email); if ( !is_wp_error($errors) ) { $redirect_to = !empty( $_POST[‘redirect_to’] ) ? $_POST[‘redirect_to’] : ‘wp-login.php?checkemail=registered’; wp_safe_redirect( … Read more