Site logo

[Support request] Add a gutenberg element to certain post types from ‘elements’

Home Forums Support [Support request] Add a gutenberg element to certain post types from ‘elements’

Home Forums Support Add a gutenberg element to certain post types from ‘elements’

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1598378
    Ayham

    Hello!

    I want to add a gutenberg block (say a table) only once from a generatepress ‘Element’ and have it apply to all posts of a certain type.

    From ‘Elements’ I created a blocktype = ‘hook’ and hook = ‘generate_inside_containter’ but it does not work. I tried other variations that didn’t work either.

    If what I want to do is possible what should the parameter be?

    Thanks.

    #1598433
    David
    Staff
    Customer Support

    Hi there,

    whats the exact issue?
    Is it just the styling ?

    #1598509
    Ayham

    I am sorry I did not explain well.

    The problem is that the block I want added (for example a table) does not appear in the posts of the type specified.

    I would like to know what settings I should use when I create the element or whether what I am trying to do is possible.

    thanks.

    #1598531
    David
    Staff
    Customer Support

    What Display Rules have you used in the Block Element?
    And can you link me to a post where the block should be displayed?

    #1598554
    Ayham

    Thanks for responding fast.

    I am trying this element with learndash lms post types and just discovered that that the rule works for some post type ‘courses’ but not ‘lessons’ or ‘topics’.

    Block type = Hook
    Hook = generate_after_content
    Priority = 10 (This is default)
    Location = Lesson

    If the location is ‘course’ it works.

    In any case, I will experiment a bit with tags to see if I can get it to work and let you know.

    thanks.

    #1599133
    David
    Staff
    Customer Support

    Let us know 🙂

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.