Blog

Building a simple Custom Widget with Javascript

Are you building a custom Elementor widget, and looking to add some Javascript functionality to it? You’ve come to the right place. Elementor has a best practice for adding Javascript handlers to custom widgets, which we are going to cover in this blog post. We will build a simple, Javascript-powered widget together, explaining every step of the process.

In addition to this blog post, our Developers site also has official documentation on adding JS to widgets.

(more…)

New Control: Icons

Elementor 2.6.0 is just around the corner and with it, we are introducing a new Icons control which loads the new Elementor’s homemade Icon Library.

This new control allows easier upgrading of Font Awesome versions while supporting older versions for backward compatibility. On top of that, it introduces support for SVG icons and in the near future, will support custom icon font libraries.

Usage:

Start by adding the control to your widget in the widget’s class _register_controls() method, just like any other control in Elementor.

protected function _register_controls() {
	//...
	$this->add_control(
		'icon',
		[
			'label' => __( 'Icon', 'text-domain' ),
			'type' => Controls_Manager::ICONS,
			'default' => [
				'value' => 'fas fa-star',
				'library' => 'solid',
			],
		]
	);
	//...
}
(more…)

v2.6.0: Planned Deprecations

Hello everyone – we are getting ready to release version 2.6.0.

From now on we will update every time we release a new version of Elementor & Elementor Pro. Here is the planned deprecation list:

Functions & Methods

Soft Deprecation

Function / Method NameChanges Made
Utils::is_ajax()

Replaced by: wp_doing_ajax()


Located in: includes/utils.php


Hard deprecation: 3.0.0


Deletion: 3.4.0

(more…)