Skip to content

Instantly share code, notes, and snippets.

@ramiy
Last active February 8, 2018 21:12
Show Gist options
  • Save ramiy/a6cee932a2e52b43d7a591edfaf2a7da to your computer and use it in GitHub Desktop.
Save ramiy/a6cee932a2e52b43d7a591edfaf2a7da to your computer and use it in GitHub Desktop.
Add new Elementor Widget Category
function add_elementor_widget_categories() {
\Elementor\Plugin::instance()->elements_manager->add_category(
'theme-elements',
[
'title' => __( 'Theme Elements', 'text-domain' ),
'icon' => 'fa fa-plug',
],
2 // position
);
\Elementor\Plugin::instance()->elements_manager->add_category(
'other-elements',
[
'title' => __( 'Other Elements', 'text-domain' ),
'icon' => 'fa fa-plug',
],
3 // position
);
}
add_action( 'elementor/init', 'add_elementor_widget_categories' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment