- This topic has 1 reply, 2 voices, and was last updated 5 years, 3 months ago by .
 
Viewing 2 posts - 1 through 2 (of 2 total)
	
Viewing 2 posts - 1 through 2 (of 2 total)
	
- You must be logged in to reply to this topic.
 


Home › Forums › Pro Themes › Education Hub Pro › Comments shortcode in sidebar isn’t working
I am trying to get the comments section on the page to appear in the sidebar. I pasted this in my function.php:
function my_wpdiscuz_shortcode() {
    if (file_exists(ABSPATH . ‘wp-content/plugins/wpdiscuz/templates/comment/comment-form.php’)) {
        ob_start();
        include_once ABSPATH . ‘wp-content/plugins/wpdiscuz/templates/comment/comment-form.php’;
        return ob_get_clean();
    }
}
add_shortcode(‘wpdiscuz_comments’, ‘my_wpdiscuz_shortcode’);
Then I can pasted [wpdiscz_comments] in a text widget in my sidebar. I am just getting a blank screen where the comments should be.
Hello,
Regarding your query, the shortcode you have used might not be compatible with the theme which is why the sidebar is not supporting the shortcode.
Also, we do not have any shortcode that is used for the comment section.
If you have further queries/confusion, kindly let us know.
Regards.
| Cookie | Duration | Description | 
|---|---|---|
| cookielawinfo-checkbox-analytics | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics". | 
| cookielawinfo-checkbox-functional | 11 months | The cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional". | 
| cookielawinfo-checkbox-necessary | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary". | 
| cookielawinfo-checkbox-others | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other. | 
| cookielawinfo-checkbox-performance | 11 months | This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance". | 
| viewed_cookie_policy | 11 months | The cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data. | 



