• Resolved doctorproctor

    (@doctorproctor)


    Greetings — I’m building a Jetpack-based site and would like to enable comments on a CPT I’m designing. Jetpack comments display fine on regular pages/posts, but not on the CPT. At this point I’m hoping to diagnose whether this is a Jetpack issue, an issue with my theme (Genesis framework), or an issue with my CPT plugins (Toolset Types/Views).

    Re. Genesis theme: I’m following the advice here to enable comments on a Genesis theme-based CPT, specifically adding this functions.php snippet:

    add_post_type_support( 'cpt-name-here', 'comments' );

    It does not, however, seem to make a difference. (Since my CPT is defined via Toolset Types, I’ve tried both wpcf-cpt-name and cpt-name, as I believe they add a prefix to their CPTs.) So, I’m not sure the problem lies with the Genesis theme. (Side note: years ago I experienced occasional problems with hyphens in CPT names…still relevant?)

    Re. Toolset: Toolset Types allows one to enable comments when defining the CPT, which I’ve done. I’ve also temporarily disabled the Toolset content template I’m using to display the CPT, to eliminate that possibility (& thus display with standard single.php-ish template)…no improvement.

    So, I’m down to Jetpack (we have latest v. plugin) possibly being an issue. Again, Jetpack works fine on all standard posts/pages. Can you think of any reason why Jetpack would not play well with supporting comments on my CPT?

    Regards,

    Jim P.

    • This topic was modified 8 years, 3 months ago by doctorproctor.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic ??

    Jetpack’s Comments module is hooked into the regular WordPress comment form, and replaces it when the Comments module is active. However, if the module is inactive or if the regular comment form isn’t displayed on the page in the first place, Jetpack won’t help you add the form to the page.

    Comments, on the other hand, are handled by your theme. They will appear regardless of whether comments are enabled on that post, and regardless of the way the comment form is displayed. Jetpack’s Comments module consequently doesn’t have any impact on the way comments are displayed.

    What do you see on your site when looking at a Custom Post Type single page? Do you see comments, but no comment form? Do you see both comments and the comment form, but no Jetpack comment form even though Jetpack’s Comments module is active?

    The best way to rule out a conflict with Jetpack is to deactivate Jetpack’s Comments module under Jetpack > Settings > Engagement. Once that’s done, you can continue debugging:

    1. Do you see a “Discussion” option when clicking on “Screen Options” when editing a Custom Post Type? https://i.wpne.ws/iLSk If you don’t see that option, it means your Custom Post Type doesn’t support comments. You’ll need to look at how the Post Type is registered (i.e. Toolset Types).
    2. If you see that option in “Screen Options”, are comments enabled in the meta box below the visual editor? https://i.wpne.ws/iKsx If they are enabled, but you see no comment form on the frontend, the problem is linked to your theme.

    I hope this helps.

    Thread Starter doctorproctor

    (@doctorproctor)

    Thank you, super helpful reply! I didn’t think of temporarily turning off Jetpack comments (which didn’t change anything, thus vindicating Jetpack) or switching to a default theme (which fixed it!), so it’s related to my Genesis theme, or possibly how my Genesis theme relates to my Toolset-defined CPT…nothing to do with Jetpack!

    Sure appreciate,

    Jim P.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘enable jetpack comments on CPT’ is closed to new replies.