- This topic has 24 replies, 3 voices, and was last updated 3 years, 2 months ago by Ying.
-
AuthorPosts
-
February 17, 2021 at 1:58 pm #1662362Ian
Am I missing something. I created a Block Element of social icons using GB Buttons. Is there a way to grab this as a shortcode and inject it into the default WP sidebar?
February 17, 2021 at 2:03 pm #1662365YingStaffCustomer SupportHi Ian,
You could choose hook as block type, choose
generate_before_sidebar
orgenerate_after_sidebar
as hook. Here’s a visual guide for GP hooks.Hope it helps π
February 17, 2021 at 2:05 pm #1662368IanThanks Ying. The Social Icons need to be the 2nd widget in the sidebar. Is there any other way to do this?
Also, I was hoping to use GB to build out the icons. I think I may be missing something here. Given the great tools like Blocks and Elements, it seems to be doable. lol
February 17, 2021 at 2:07 pm #1662373YingStaffCustomer SupportYes, could use some CSS to re-order the widgets in sidebar π
Please link us to the site in question using the private info field so we can have a look.
February 17, 2021 at 2:08 pm #1662376IanThank you. I have added a link to a post. You can see the social icons right now. I want to replace this using GB Buttons.
February 17, 2021 at 2:40 pm #1662408YingStaffCustomer SupportAlright, set block element using
generate_before_right_sidebar
hook, and here’s the CSS to position the sidebar content:.inside-right-sidebar { display: flex; flex-direction: column; } .inside-right-sidebar #search-8 { order: -1; }
February 17, 2021 at 2:42 pm #1662410IanHi Ying,
If I am using Blocks (GB Buttons module) to make these icons, how can I hook it? There is no hook function within Element > Blocks Element. Again, I may be missing something here.
Come to think of it, since Blocks is a thing now, I wonder if we can use GB to build the entire sidebar and insert it this way?
February 17, 2021 at 2:51 pm #1662425YingStaffCustomer SupportFirst option use block element as a hook:
1. Choose hook as block type:
https://docs.generatepress.com/article/block-element-overview/#block-type2. Choose
generate_before_right_sidebar
as hook.3. Add CSS to customizer > additional css.
Second option, yes, you can build the entire sidebar using blocks. Just choose right sidebar as block type, it will replace the default sidebar you are having now.
https://docs.generatepress.com/article/block-element-overview/#right-sidebar-typeLet me know π
February 17, 2021 at 2:57 pm #1662437IanWhen I choose Element = Hook, there is no way to launch Gutenberg to use Generate Blocks to build the icons using GB Buttons?
February 17, 2021 at 3:01 pm #1662439YingStaffCustomer SupportWell all the steps are based on it’s a Block element, not Hook element or Header element or any other elements. π
So before all the steps I mentioned in my previous reply, you go to Appearance > Elements, Create a Block element.
https://docs.generatepress.com/article/block-element-overview/#creating-a-block-elementFebruary 17, 2021 at 3:05 pm #1662445IanWait, I see the issue now. This site is still running the Classic Editors so we have installed a plugin to be able to switch Between Classic and Block Editor. When choosing Block, I see Block Type in the classic Editor. But once I switch to Block Editor, the Block Type options disappear even if I switch back to the Classic Editor. Glitch?
February 17, 2021 at 3:11 pm #1662450YingStaffCustomer SupportAny chance you can link us the login info?
You can use the private information field.
February 17, 2021 at 3:14 pm #1662452IanHi Ying, done. Let me know what else I can provide!
February 17, 2021 at 3:23 pm #1662459YingStaffCustomer SupportI just had a look, got what you were struggling with.
Once you deactivate classic editor plugin, you can add a new Block element with all the settings available π
February 17, 2021 at 3:27 pm #1662462IanDoh! Site has a long history, not ready to deactivate that yet. May I ask if you deactivated that plugin when you logged in?
If so, do you think all old content will stay as is until someone edits with Block editor and choose Convert to Blocks? We have some very old content that rocks so don’t want to break anything.
-
AuthorPosts
- You must be logged in to reply to this topic.