From f01b8939e16153a2681549159859b398e38d6442 Mon Sep 17 00:00:00 2001
From: Michael Makijenko
Date: Thu, 28 Oct 2021 12:12:10 +0300
Subject: [PATCH 1/4] Update all vc appearances with wpb
---
README.md | 12 ++--
README.txt | 12 ++--
...ss-visual-composer-multilanguage-admin.php | 66 +++++++++----------
.../visual-composer-multilanguage-admin.css | 2 +-
...l-composer-multilanguage-admin-display.php | 4 +-
...isual-composer-multilanguage-activator.php | 10 +--
...ual-composer-multilanguage-deactivator.php | 10 +--
...ass-visual-composer-multilanguage-i18n.php | 12 ++--
...s-visual-composer-multilanguage-loader.php | 10 +--
.../class-visual-composer-multilanguage.php | 44 ++++++-------
...s-visual-composer-multilanguage-public.php | 40 +++++------
...-composer-multilanguage-public-display.php | 4 +-
uninstall.php | 2 +-
visual-composer-multilanguage.php | 34 +++++-----
14 files changed, 131 insertions(+), 131 deletions(-)
diff --git a/README.md b/README.md
index 4f2ac30..01a3c91 100644
--- a/README.md
+++ b/README.md
@@ -2,26 +2,26 @@
Author URI: https://allurewebsolutions.com
Plugin URI: https://vc-multilanguage.allureprojects.com/
-Tags: visual composer, multilanguage, multi-language, translate, translation
+Tags: wpbakery page builder, multilanguage, multi-language, translate, translation
Donate link: https://allurewebsolutions.com/product/donation
Tested up to: 5.3
Stable tag: 2.1.2
-This is an add-on plugin for WPBakery Visual Composer that adds multilanguage support and functionality. Version 2.0 now also has automatic translations that you can turn on.
+This is an add-on plugin for WPBakery Page Builder that adds multilanguage support and functionality. Version 2.0 now also has automatic translations that you can turn on.
## Description
-This is an add-on plugin for WPBakery Visual Composer that adds functionality of a language switcher, making it very easy to create a multi-language site without an additional multi-language or translation plugin.
+This is an add-on plugin for WPBakery Page Builder that adds functionality of a language switcher, making it very easy to create a multi-language site without an additional multi-language or translation plugin.
In version 2.0, we've added support for automatic translations using the Google Cloud Translate API.
-[Full Setup Instructions & Walkthrough](https://allurewebsolutions.com/visual-composer-multilanguage-plugin)
+[Full Setup Instructions & Walkthrough](https://allurewebsolutions.com/wpbakery-page-builder-multilanguage-plugin)
-[Demo](https://vc-multilanguage.allureprojects.com)
+[Demo](https://wpb-multilanguage.allureprojects.com)
## Installation
-1) Activate the plugin. Must have Visual Composer also activated.
+1) Activate the plugin. Must have WPBakery Page Builder also activated.
2) Go to plugin settings and input the languages you would like to support.
3) Go to VC editor and add rows. Select language from the dropdown and add a class of "language" to the extra classes section.
4) For auto translation, you follow step 3, but leave the text-block inside the row empty.
diff --git a/README.txt b/README.txt
index 26ad2f3..157bfaa 100755
--- a/README.txt
+++ b/README.txt
@@ -2,24 +2,24 @@
Contributors: allurewebsolutions
Author URI: https://allurewebsolutions.com
Plugin URI: https://vc-multilanguage.allureprojects.com/
-Tags: visual composer, multilanguage, multi-language, translate, translation
+Tags: wpbakery page builder, multilanguage, multi-language, translate, translation
Donate link: https://allurewebsolutions.com/product/donation
Tested up to: 5.8
Stable tag: 2.1.2
-This is an add-on plugin for WPBakery Visual Composer that adds multilanguage support and functionality. Version 2.0 now also has automatic translations that you can turn on.
+This is an add-on plugin for WPBakery Page Builder that adds multilanguage support and functionality. Version 2.0 now also has automatic translations that you can turn on.
== Description ==
-This is an add-on plugin for WPBakery Visual Composer that adds functionality of a language switcher, making it very easy to create a multi-language site without an additional multi-language or translation plugin.
+This is an add-on plugin for WPBakery Page Builder that adds functionality of a language switcher, making it very easy to create a multi-language site without an additional multi-language or translation plugin.
In version 2.0, we've added support for automatic translations using the Google Cloud Translate API.
-[Full Setup Instructions & Walkthrough](https://allurewebsolutions.com/visual-composer-multilanguage-plugin)
+[Full Setup Instructions & Walkthrough](https://allurewebsolutions.com/wpbakery-page-builder-multilanguage-plugin)
-[Demo](https://vc-multilanguage.allureprojects.com)
+[Demo](https://wpb-multilanguage.allureprojects.com)
== Installation ==
-1) Activate the plugin. Must have Visual Composer also activated.
+1) Activate the plugin. Must have WPBakery Page Builder also activated.
2) Go to plugin settings and input the languages you would like to support.
3) Go to VC editor and add rows. Select language from the dropdown and add a class of "language" to the extra classes section.
4) For auto translation, you follow step 3, but leave the text-block inside the row empty.
diff --git a/admin/class-visual-composer-multilanguage-admin.php b/admin/class-visual-composer-multilanguage-admin.php
index a05b30b..b527efe 100755
--- a/admin/class-visual-composer-multilanguage-admin.php
+++ b/admin/class-visual-composer-multilanguage-admin.php
@@ -6,8 +6,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/admin
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/admin
*/
/**
@@ -16,11 +16,11 @@
* Defines the plugin name, version, and two examples hooks for how to
* enqueue the admin-specific stylesheet and JavaScript.
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/admin
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/admin
* @author Allure Web Solutions
*/
-class Visual_Composer_Multilanguage_Admin {
+class Wpbakery_Page_Builder_Multilanguage_Admin {
/**
* The options name to be used in this plugin
@@ -29,7 +29,7 @@ class Visual_Composer_Multilanguage_Admin {
* @access private
* @var string $option_name Option name of this plugin
*/
- private $option_name = 'visual_composer_multilanguage';
+ private $option_name = 'wpbakery_page_builder_multilanguage';
/**
* The ID of this plugin.
@@ -75,15 +75,15 @@ public function enqueue_styles() {
* This function is provided for demonstration purposes only.
*
* An instance of this class should be passed to the run() function
- * defined in Visual_Composer_Multilanguage_Loader as all of the hooks are defined
+ * defined in Wpbakery_Page_Builder_Multilanguage_Loader as all of the hooks are defined
* in that particular class.
*
- * The Visual_Composer_Multilanguage_Loader will then create the relationship
+ * The Wpbakery_Page_Builder_Multilanguage_Loader will then create the relationship
* between the defined hooks and the functions defined in this
* class.
*/
- wp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/visual-composer-multilanguage-admin.css', array(), $this->version, 'all' );
+ wp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/wpbakery-page-builder-multilanguage-admin.css', array(), $this->version, 'all' );
}
@@ -98,15 +98,15 @@ public function enqueue_scripts() {
* This function is provided for demonstration purposes only.
*
* An instance of this class should be passed to the run() function
- * defined in Visual_Composer_Multilanguage_Loader as all of the hooks are defined
+ * defined in Wpbakery_Page_Builder_Multilanguage_Loader as all of the hooks are defined
* in that particular class.
*
- * The Visual_Composer_Multilanguage_Loader will then create the relationship
+ * The Wpbakery_Page_Builder_Multilanguage_Loader will then create the relationship
* between the defined hooks and the functions defined in this
* class.
*/
- wp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/visual-composer-multilanguage-admin.js', array( 'jquery' ), $this->version, false );
+ wp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/wpbakery-page-builder-multilanguage-admin.js', array( 'jquery' ), $this->version, false );
}
@@ -118,8 +118,8 @@ public function enqueue_scripts() {
public function add_options_page() {
$this->plugin_screen_hook_suffix = add_options_page(
- __( 'VC Multilanguage Settings', 'visual-composer-multilanguage' ),
- __( 'VC Multilanguage', 'visual-composer-multilanguage' ),
+ __( 'VC Multilanguage Settings', 'wpbakery-page-builder-multilanguage' ),
+ __( 'VC Multilanguage', 'wpbakery-page-builder-multilanguage' ),
'manage_options',
$this->plugin_name,
array( $this, 'display_options_page' )
@@ -135,7 +135,7 @@ public function add_options_page() {
public function register_setting() {
add_settings_section(
$this->option_name . '_general',
- __( 'General', 'visual-composer-multilanguage' ),
+ __( 'General', 'wpbakery-page-builder-multilanguage' ),
array( $this, $this->option_name . '_general_cb' ),
$this->plugin_name
);
@@ -143,7 +143,7 @@ public function register_setting() {
// Supported languages text field
add_settings_field(
$this->option_name . '_languages',
- __( 'Languages', 'visual-composer-multilanguage' ),
+ __( 'Languages', 'wpbakery-page-builder-multilanguage' ),
array( $this, $this->option_name . '_languages_cb' ),
$this->plugin_name,
$this->option_name . '_general',
@@ -153,7 +153,7 @@ public function register_setting() {
// Supported languages text field
add_settings_field(
$this->option_name . '_default_language',
- __( 'Select Default Language', 'visual-composer-multilanguage' ),
+ __( 'Select Default Language', 'wpbakery-page-builder-multilanguage' ),
array( $this, $this->option_name . '_default_language_cb' ),
$this->plugin_name,
$this->option_name . '_general',
@@ -163,7 +163,7 @@ public function register_setting() {
// Activate language switcher
add_settings_field(
$this->option_name . '_switcher',
- __( 'Activate Language Switcher', 'visual-composer-multilanguage' ),
+ __( 'Activate Language Switcher', 'wpbakery-page-builder-multilanguage' ),
array( $this, $this->option_name . '_switcher_cb' ),
$this->plugin_name,
$this->option_name . '_general',
@@ -173,7 +173,7 @@ public function register_setting() {
// Activate automatic translations
add_settings_field(
$this->option_name . '_autotranslate',
- __( 'Activate Automatic Translations', 'visual-composer-multilanguage' ),
+ __( 'Activate Automatic Translations', 'wpbakery-page-builder-multilanguage' ),
array( $this, $this->option_name . '_autotranslate_cb' ),
$this->plugin_name,
$this->option_name . '_general',
@@ -183,7 +183,7 @@ public function register_setting() {
// Activate styling
add_settings_field(
$this->option_name . '_styling',
- __( 'Activate Styling', 'visual-composer-multilanguage' ),
+ __( 'Activate Styling', 'wpbakery-page-builder-multilanguage' ),
array( $this, $this->option_name . '_styling_cb' ),
$this->plugin_name,
$this->option_name . '_general',
@@ -193,7 +193,7 @@ public function register_setting() {
// Google API Key
add_settings_field(
$this->option_name . '_googleapikey',
- __( 'Google Cloud Translate API Key', 'visual-composer-multilanguage' ),
+ __( 'Google Cloud Translate API Key', 'wpbakery-page-builder-multilanguage' ),
array( $this, $this->option_name . '_googleapikey_cb' ),
$this->plugin_name,
$this->option_name . '_general',
@@ -233,14 +233,14 @@ public function register_setting() {
*
* @since 1.0.0
*/
- public function visual_composer_multilanguage_languages_cb() {
+ public function wpbakery_page_builder_multilanguage_languages_cb() {
$languages = get_option( $this->option_name . '_languages' );
?>
option_name . '_switcher' );
?>
';
+ public function wpbakery_page_builder_multilanguage_general_cb() {
+ echo '
' . __( 'List languages you would like supported, separated by a comma.', 'wpbakery-page-builder-multilanguage' ) . '
';
}
/**
@@ -347,7 +347,7 @@ public function visual_composer_multilanguage_general_cb() {
* @since 1.0.0
*/
public function display_options_page() {
- include_once 'partials/visual-composer-multilanguage-admin-display.php';
+ include_once 'partials/wpbakery-page-builder-multilanguage-admin-display.php';
}
}
diff --git a/admin/css/visual-composer-multilanguage-admin.css b/admin/css/visual-composer-multilanguage-admin.css
index b772548..a60da71 100755
--- a/admin/css/visual-composer-multilanguage-admin.css
+++ b/admin/css/visual-composer-multilanguage-admin.css
@@ -3,6 +3,6 @@
* included in this file.
*/
-.settings_page_visual-composer-multilanguage input[type=text] {
+.settings_page_wpbakery-page-builder-multilanguage input[type=text] {
width: 100%;
}
\ No newline at end of file
diff --git a/admin/partials/visual-composer-multilanguage-admin-display.php b/admin/partials/visual-composer-multilanguage-admin-display.php
index 6b0ccde..b521975 100755
--- a/admin/partials/visual-composer-multilanguage-admin-display.php
+++ b/admin/partials/visual-composer-multilanguage-admin-display.php
@@ -8,8 +8,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/admin/partials
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/admin/partials
*/
?>
diff --git a/includes/class-visual-composer-multilanguage-activator.php b/includes/class-visual-composer-multilanguage-activator.php
index 834a1db..4cfa19e 100755
--- a/includes/class-visual-composer-multilanguage-activator.php
+++ b/includes/class-visual-composer-multilanguage-activator.php
@@ -6,8 +6,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
*/
/**
@@ -16,11 +16,11 @@
* This class defines all code necessary to run during the plugin's activation.
*
* @since 1.0.0
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
* @author Allure Web Solutions
*/
-class Visual_Composer_Multilanguage_Activator {
+class Wpbakery_Page_Builder_Multilanguage_Activator {
/**
* Short Description. (use period)
diff --git a/includes/class-visual-composer-multilanguage-deactivator.php b/includes/class-visual-composer-multilanguage-deactivator.php
index 30b75a2..0d8c329 100755
--- a/includes/class-visual-composer-multilanguage-deactivator.php
+++ b/includes/class-visual-composer-multilanguage-deactivator.php
@@ -6,8 +6,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
*/
/**
@@ -16,11 +16,11 @@
* This class defines all code necessary to run during the plugin's deactivation.
*
* @since 1.0.0
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
* @author Allure Web Solutions
*/
-class Visual_Composer_Multilanguage_Deactivator {
+class Wpbakery_Page_Builder_Multilanguage_Deactivator {
/**
* Short Description. (use period)
diff --git a/includes/class-visual-composer-multilanguage-i18n.php b/includes/class-visual-composer-multilanguage-i18n.php
index 3966d2c..c706610 100755
--- a/includes/class-visual-composer-multilanguage-i18n.php
+++ b/includes/class-visual-composer-multilanguage-i18n.php
@@ -9,8 +9,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
*/
/**
@@ -20,11 +20,11 @@
* so that it is ready for translation.
*
* @since 1.0.0
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
* @author Allure Web Solutions
*/
-class Visual_Composer_Multilanguage_i18n {
+class Wpbakery_Page_Builder_Multilanguage_i18n {
/**
@@ -35,7 +35,7 @@ class Visual_Composer_Multilanguage_i18n {
public function load_plugin_textdomain() {
load_plugin_textdomain(
- 'visual-composer-multilanguage',
+ 'wpbakery-page-builder-multilanguage',
false,
dirname( dirname( plugin_basename( __FILE__ ) ) ) . '/languages/'
);
diff --git a/includes/class-visual-composer-multilanguage-loader.php b/includes/class-visual-composer-multilanguage-loader.php
index eae4ebc..93f0abc 100755
--- a/includes/class-visual-composer-multilanguage-loader.php
+++ b/includes/class-visual-composer-multilanguage-loader.php
@@ -6,8 +6,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
*/
/**
@@ -17,11 +17,11 @@
* the plugin, and register them with the WordPress API. Call the
* run function to execute the list of actions and filters.
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
* @author Allure Web Solutions
*/
-class Visual_Composer_Multilanguage_Loader {
+class Wpbakery_Page_Builder_Multilanguage_Loader {
/**
* The array of actions registered with WordPress.
diff --git a/includes/class-visual-composer-multilanguage.php b/includes/class-visual-composer-multilanguage.php
index 511c66c..bc3dcf7 100755
--- a/includes/class-visual-composer-multilanguage.php
+++ b/includes/class-visual-composer-multilanguage.php
@@ -9,8 +9,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
*/
/**
@@ -23,11 +23,11 @@
* version of the plugin.
*
* @since 1.0.0
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/includes
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/includes
* @author Allure Web Solutions
*/
-class Visual_Composer_Multilanguage {
+class Wpbakery_Page_Builder_Multilanguage {
/**
* The loader that's responsible for maintaining and registering all hooks that power
@@ -35,7 +35,7 @@ class Visual_Composer_Multilanguage {
*
* @since 1.0.0
* @access protected
- * @var Visual_Composer_Multilanguage_Loader $loader Maintains and registers all hooks for the plugin.
+ * @var Wpbakery_Page_Builder_Multilanguage_Loader $loader Maintains and registers all hooks for the plugin.
*/
protected $loader;
@@ -68,7 +68,7 @@ class Visual_Composer_Multilanguage {
*/
public function __construct() {
- $this->plugin_name = 'visual-composer-multilanguage';
+ $this->plugin_name = 'wpbakery-page-builder-multilanguage';
$this->version = '2.0';
$this->load_dependencies();
@@ -83,10 +83,10 @@ public function __construct() {
*
* Include the following files that make up the plugin:
*
- * - Visual_Composer_Multilanguage_Loader. Orchestrates the hooks of the plugin.
- * - Visual_Composer_Multilanguage_i18n. Defines internationalization functionality.
- * - Visual_Composer_Multilanguage_Admin. Defines all hooks for the admin area.
- * - Visual_Composer_Multilanguage_Public. Defines all hooks for the public side of the site.
+ * - Wpbakery_Page_Builder_Multilanguage_Loader. Orchestrates the hooks of the plugin.
+ * - Wpbakery_Page_Builder_Multilanguage_i18n. Defines internationalization functionality.
+ * - Wpbakery_Page_Builder_Multilanguage_Admin. Defines all hooks for the admin area.
+ * - Wpbakery_Page_Builder_Multilanguage_Public. Defines all hooks for the public side of the site.
*
* Create an instance of the loader which will be used to register the hooks
* with WordPress.
@@ -100,33 +100,33 @@ private function load_dependencies() {
* The class responsible for orchestrating the actions and filters of the
* core plugin.
*/
- require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-visual-composer-multilanguage-loader.php';
+ require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wpbakery-page-builder-multilanguage-loader.php';
/**
* The class responsible for defining internationalization functionality
* of the plugin.
*/
- require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-visual-composer-multilanguage-i18n.php';
+ require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-wpbakery-page-builder-multilanguage-i18n.php';
/**
* The class responsible for defining all actions that occur in the admin area.
*/
- require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-visual-composer-multilanguage-admin.php';
+ require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-wpbakery-page-builder-multilanguage-admin.php';
/**
* The class responsible for defining all actions that occur in the public-facing
* side of the site.
*/
- require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-visual-composer-multilanguage-public.php';
+ require_once plugin_dir_path( dirname( __FILE__ ) ) . 'public/class-wpbakery-page-builder-multilanguage-public.php';
- $this->loader = new Visual_Composer_Multilanguage_Loader();
+ $this->loader = new Wpbakery_Page_Builder_Multilanguage_Loader();
}
/**
* Define the locale for this plugin for internationalization.
*
- * Uses the Visual_Composer_Multilanguage_i18n class in order to set the domain and to register the hook
+ * Uses the Wpbakery_Page_Builder_Multilanguage_i18n class in order to set the domain and to register the hook
* with WordPress.
*
* @since 1.0.0
@@ -134,7 +134,7 @@ private function load_dependencies() {
*/
private function set_locale() {
- $plugin_i18n = new Visual_Composer_Multilanguage_i18n();
+ $plugin_i18n = new Wpbakery_Page_Builder_Multilanguage_i18n();
$this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
@@ -149,7 +149,7 @@ private function set_locale() {
*/
private function define_admin_hooks() {
- $plugin_admin = new Visual_Composer_Multilanguage_Admin( $this->get_plugin_name(), $this->get_version() );
+ $plugin_admin = new Wpbakery_Page_Builder_Multilanguage_Admin( $this->get_plugin_name(), $this->get_version() );
$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts' );
@@ -169,12 +169,12 @@ private function define_admin_hooks() {
*/
private function define_public_hooks() {
- $plugin_public = new Visual_Composer_Multilanguage_Public( $this->get_plugin_name(), $this->get_version() );
+ $plugin_public = new Wpbakery_Page_Builder_Multilanguage_Public( $this->get_plugin_name(), $this->get_version() );
$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_scripts' );
- $this->loader->add_action( 'wp_loaded', $plugin_public, 'extend_visual_composer' );
+ $this->loader->add_action( 'wp_loaded', $plugin_public, 'extend_wpbakery_page_builder' );
$this->loader->add_action( 'wp_footer', $plugin_public, 'add_language_switcher' );
$this->loader->add_action( 'wp_footer', $plugin_public, 'plugin_settings_passthrough' );
@@ -204,7 +204,7 @@ public function get_plugin_name() {
* The reference to the class that orchestrates the hooks with the plugin.
*
* @since 1.0.0
- * @return Visual_Composer_Multilanguage_Loader Orchestrates the hooks of the plugin.
+ * @return Wpbakery_Page_Builder_Multilanguage_Loader Orchestrates the hooks of the plugin.
*/
public function get_loader() {
return $this->loader;
diff --git a/public/class-visual-composer-multilanguage-public.php b/public/class-visual-composer-multilanguage-public.php
index 64eaa23..b8c0b71 100755
--- a/public/class-visual-composer-multilanguage-public.php
+++ b/public/class-visual-composer-multilanguage-public.php
@@ -6,8 +6,8 @@
* @link https://allurewebsolutions.com
* @since 1.0.0
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/public
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/public
*/
/**
@@ -16,11 +16,11 @@
* Defines the plugin name, version, and two examples hooks for how to
* enqueue the admin-specific stylesheet and JavaScript.
*
- * @package Visual_Composer_Multilanguage
- * @subpackage Visual_Composer_Multilanguage/public
+ * @package Wpbakery_Page_Builder_Multilanguage
+ * @subpackage Wpbakery_Page_Builder_Multilanguage/public
* @author Allure Web Solutions
*/
-class Visual_Composer_Multilanguage_Public {
+class Wpbakery_Page_Builder_Multilanguage_Public {
/**
* The ID of this plugin.
@@ -66,15 +66,15 @@ public function enqueue_styles() {
* This function is provided for demonstration purposes only.
*
* An instance of this class should be passed to the run() function
- * defined in Visual_Composer_Multilanguage_Loader as all of the hooks are defined
+ * defined in Wpbakery_Page_Builder_Multilanguage_Loader as all of the hooks are defined
* in that particular class.
*
- * The Visual_Composer_Multilanguage_Loader will then create the relationship
+ * The Wpbakery_Page_Builder_Multilanguage_Loader will then create the relationship
* between the defined hooks and the functions defined in this
* class.
*/
- wp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/visual-composer-multilanguage-public.css', array(), $this->version, 'all' );
+ wp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/wpbakery-page-builder-multilanguage-public.css', array(), $this->version, 'all' );
}
@@ -89,21 +89,21 @@ public function enqueue_scripts() {
* This function is provided for demonstration purposes only.
*
* An instance of this class should be passed to the run() function
- * defined in Visual_Composer_Multilanguage_Loader as all of the hooks are defined
+ * defined in Wpbakery_Page_Builder_Multilanguage_Loader as all of the hooks are defined
* in that particular class.
*
- * The Visual_Composer_Multilanguage_Loader will then create the relationship
+ * The Wpbakery_Page_Builder_Multilanguage_Loader will then create the relationship
* between the defined hooks and the functions defined in this
* class.
*/
- wp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/visual-composer-multilanguage-public.js', array( 'jquery' ), $this->version, false );
+ wp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/wpbakery-page-builder-multilanguage-public.js', array( 'jquery' ), $this->version, false );
wp_localize_script( $this->plugin_name, 'vc', array(
'pluginUrl' => plugin_dir_url( __FILE__ ),
'ajax_url' => admin_url( 'admin-ajax.php' ),
'siteUrl' => get_bloginfo( 'url' ),
- 'defaultLanguage' => get_option( 'visual_composer_multilanguage_default_language' ),
+ 'defaultLanguage' => get_option( 'wpbakery_page_builder_multilanguage_default_language' ),
) );
}
@@ -112,11 +112,11 @@ public function enqueue_scripts() {
/**
* Add data-lang attribute to VC Rows
*/
- public function extend_visual_composer() {
+ public function extend_wpbakery_page_builder() {
// Get languages from plugin settings
- $languages = explode( ',', str_replace( ' ', '', get_option( 'visual_composer_multilanguage_languages', 'English' ) ) );
+ $languages = explode( ',', str_replace( ' ', '', get_option( 'wpbakery_page_builder_multilanguage_languages', 'English' ) ) );
- // Add language dropdown to visual composer settings
+ // Add language dropdown to wpbakery page builder settings
if ( function_exists( 'vc_add_param' ) ) {
vc_add_param( 'vc_row', array(
'type' => 'dropdown',
@@ -137,8 +137,8 @@ public function extend_visual_composer() {
* Add language switcher
*/
public function add_language_switcher() {
- if ( get_option( 'visual_composer_multilanguage_switcher' ) === "switcher" ) {
- $languages = explode( ',', str_replace( ' ', '', get_option( 'visual_composer_multilanguage_languages', 'English' ) ) );
+ if ( get_option( 'wpbakery_page_builder_multilanguage_switcher' ) === "switcher" ) {
+ $languages = explode( ',', str_replace( ' ', '', get_option( 'wpbakery_page_builder_multilanguage_languages', 'English' ) ) );
$switcher_html = '