t'.
*
* @return string
*/
final protected function get_assets_url( $file_name, $file_extension, $relative_url = null, $add_min_suffix = 'default' ) {
static $is_test_mode = null;
if ( null === $is_test_mode ) {
$is_test_mode = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG || defined( 'ELEMENTOR_TESTS' ) && ELEMENTOR_TESTS;
}
if ( ! $relative_url ) {
$relative_url = $this->get_assets_relative_url() . $file_extension . '/';
}
$url = $this->get_assets_base_url() . $relative_url . $file_name;
if ( 'default' === $add_min_suffix ) {
$add_min_suffix = ! $is_test_mode;
}
if ( $add_min_suffix ) {
$url .= '.min';
}
return $url . '.' . $file_extension;
}
/**
* Get js assets url
*
* @since 2.3.0
* @access protected
*
* @param string $file_name
* @param string $relative_url Optional. Default is null.
* @param string $add_min_suffix Optional. Default is 'default'.
*
* @return string
*/
final protected function get_js_assets_url( $file_name, $relative_url = null, $add_min_suffix = 'default' ) {
return $this->get_assets_url( $file_name, 'js', $relative_url, $add_min_suffix );
}
/**
* Get css assets url
*
* @since 2.3.0
* @access protected
*
* @param string $file_name
* @param string $relative_url Optional. Default is null.
* @param string $add_min_suffix Optional. Default is 'default'.
* @param bool $add_direction_suffix Optional. Default is `false`
*
* @return string
*/
final protected function get_css_assets_url( $file_name, $relative_url = null, $add_min_suffix = 'default', $add_direction_suffix = false ) {
static $direction_suffix = null;
if ( ! $direction_suffix ) {
$direction_suffix = is_rtl() ? '-rtl' : '';
}
if ( $add_direction_suffix ) {
$file_name .= $direction_suffix;
}
return $this->get_assets_url( $file_name, 'css', $relative_url, $add_min_suffix );
}
/**
* Get Frontend File URL
*
* Returns the URL for the CSS file to be loaded in the front end. If requested via the second parameter, a custom
* file is generated based on a passed template file name. Otherwise, the URL for the default CSS file is returned.
*
* @since 3.24.0
*
* @access public
*
* @param string $file_name
* @param boolean $has_custom_breakpoints
*
* @return string frontend file URL
*/
public function get_frontend_file_url( $file_name, $has_custom_breakpoints ) {
return Plugin::$instance->frontend->get_frontend_file_url( $file_name, $has_custom_breakpoints );
}
/**
* Get assets base url
*
* @since 2.6.0
* @access protected
*
* @return string
*/
protected function get_assets_base_url() {
return ELEMENTOR_URL;
}
/**
* Get assets relative url
*
* @since 2.3.0
* @access protected
*
* @return string
*/
protected function get_assets_relative_url() {
return 'assets/';
}
/**
* Get the module's associated widgets.
*
* @return string[]
*/
protected function get_widgets() {
return [];
}
/**
* Initialize the module related widgets.
*/
public function init_widgets() {
$widget_manager = Plugin::instance()->widgets_manager;
foreach ( $this->get_widgets() as $widget ) {
$class_name = $this->get_reflection()->getNamespaceName() . '\Widgets\\' . $widget;
$widget_manager->register( new $class_name() );
}
}
public function __construct() {
add_action( 'elementor/widgets/register', [ $this, 'init_widgets' ] );
}
}
Fatal error: Uncaught Error: Class 'Elementor\Core\Base\Module' not found in /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/core/logger/manager.php:18
Stack trace:
#0 /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/includes/autoloader.php(296): require()
#1 /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/includes/autoloader.php(332): Elementor\Autoloader::load_class('Core\\Logger\\Man...')
#2 [internal function]: Elementor\Autoloader::autoload('Elementor\\Core\\...')
#3 /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/includes/plugin.php(869): spl_autoload_call('Elementor\\Core\\...')
#4 /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/includes/plugin.php(629): Elementor\Plugin->__construct()
#5 /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/includes/plugin.php(886): Elementor\Plugin::instance()
#6 /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/elementor.php(58): require('/var/www/html/d...')
#7 /var/www/html/d in /var/www/html/dportilho.com.br/web/wp-content/plugins/elementor/core/logger/manager.php on line 18