WhatsApp Chat WP - Version 6.1.0

Version Description

  • Fix. WhatsApp premium compatibility
  • Fix. Styles fixes
Download this release

Release Info

Developer quadlayers
Plugin Icon 128x128 WhatsApp Chat WP
Version 6.1.0
Comparing to
See all releases

Code changes from version 6.0.9 to 6.1.0

includes/frontend.php CHANGED
@@ -47,51 +47,14 @@ if ( ! class_exists( 'QLWAPP_Frontend' ) ) {
47
  unset( $scheme['_scheme_form_nonce'] );
48
  foreach ( $scheme as $key => $value ) {
49
  if ( $value != '' ) {
 
 
 
50
  printf( '--%s-scheme-%s:%s;', QLWAPP_DOMAIN, esc_attr( $key ), esc_attr( $value ) );
51
  }
52
  }
53
  ?>
54
- }
55
-
56
- <?php
57
- if ( $scheme['font-family'] ) :
58
- ?>
59
- #qlwapp {
60
- font-family: var(--qlwapp-scheme-font-family);
61
- }
62
-
63
- <?php endif; ?>
64
- <?php
65
- if ( $scheme['font-size'] ) :
66
- ?>
67
- #qlwapp {
68
- font-size: calc(var(--qlwapp-scheme-font-size)*1px);
69
- }
70
-
71
- <?php endif; ?>
72
- <?php
73
- if ( $scheme['brand'] ) :
74
- ?>
75
- #qlwapp .qlwapp-toggle,
76
- #qlwapp .qlwapp-box .qlwapp-header,
77
- #qlwapp .qlwapp-box .qlwapp-user,
78
- #qlwapp .qlwapp-box .qlwapp-user:before {
79
- background-color: var(--qlwapp-scheme-brand);
80
- }
81
-
82
- <?php endif; ?>
83
- <?php
84
- if ( $scheme['text'] ) :
85
- ?>
86
- #qlwapp .qlwapp-toggle,
87
- #qlwapp .qlwapp-toggle .qlwapp-icon,
88
- #qlwapp .qlwapp-toggle .qlwapp-text,
89
- #qlwapp .qlwapp-box .qlwapp-header,
90
- #qlwapp .qlwapp-box .qlwapp-user {
91
- color: var(--qlwapp-scheme-text);
92
- }
93
-
94
- <?php endif; ?>
95
  </style>
96
  <?php
97
  }
47
  unset( $scheme['_scheme_form_nonce'] );
48
  foreach ( $scheme as $key => $value ) {
49
  if ( $value != '' ) {
50
+ if ( is_numeric( $value ) ) {
51
+ $value = "{$value}px";
52
+ }
53
  printf( '--%s-scheme-%s:%s;', QLWAPP_DOMAIN, esc_attr( $key ), esc_attr( $value ) );
54
  }
55
  }
56
  ?>
57
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
58
  </style>
59
  <?php
60
  }
includes/models/Scheme.php CHANGED
@@ -1,30 +1,29 @@
1
  <?php
2
 
3
- include_once(QLWAPP_PLUGIN_DIR . 'includes/models/QLWAPP_Model.php');
4
 
5
- class QLWAPP_Scheme extends QLWAPP_Model
6
- {
7
 
8
- protected $table = 'scheme';
9
 
10
- function get_args()
11
- {
12
 
13
- $args = array(
14
- 'font-family' => 'inherit',
15
- 'font-size' => '18',
16
- 'brand' => '',
17
- 'text' => '',
18
- 'link' => '',
19
- 'message' => '',
20
- 'label' => '',
21
- 'name' => '',
22
- );
23
- return $args;
24
- }
 
 
 
25
 
26
- function save($scheme = NULL)
27
- {
28
- return parent::save_data($this->table, $scheme);
29
- }
30
  }
1
  <?php
2
 
3
+ require_once QLWAPP_PLUGIN_DIR . 'includes/models/QLWAPP_Model.php';
4
 
5
+ class QLWAPP_Scheme extends QLWAPP_Model {
 
6
 
 
7
 
8
+ protected $table = 'scheme';
 
9
 
10
+ function get_args() {
11
+ $args = array(
12
+ 'font-family' => 'inherit',
13
+ 'font-size' => '18',
14
+ 'icon-size' => '60',
15
+ 'icon-font-size' => '24',
16
+ 'brand' => '',
17
+ 'text' => '',
18
+ 'link' => '',
19
+ 'message' => '',
20
+ 'label' => '',
21
+ 'name' => '',
22
+ );
23
+ return $args;
24
+ }
25
 
26
+ function save( $scheme = null ) {
27
+ return parent::save_data( $this->table, $scheme );
28
+ }
 
29
  }
includes/view/backend/pages/scheme.php CHANGED
@@ -1,81 +1,93 @@
1
  <div class="wrap about-wrap full-width-layout qlwrap">
2
- <form method="post" id="qlwapp_scheme_form">
3
- <table class="form-table">
4
- <tbody>
5
- <tr>
6
- <th scope="row"><?php esc_html_e('Font Family', 'wp-whatsapp-chat'); ?></th>
7
- <td>
8
- <select placeholder="<?php esc_html_e('Web Default', 'wp-whatsapp-chat'); ?>" name="font-family" value="<?php echo esc_attr($scheme['font-family']); ?>">
9
- <option value="inherit" <?php selected($scheme['font-family'], 'inherit'); ?>><?php esc_html_e('Web Default', 'wp-whatsapp-chat'); ?></option>
10
- <option value="Arial" <?php selected($scheme['font-family'], 'Arial'); ?>>Arial (sans-serif)</option>
11
- <option value="Verdana" <?php selected($scheme['font-family'], 'Verdana'); ?>>Verdana (sans-serif)</option>
12
- <option value="Helvetica" <?php selected($scheme['font-family'], 'Helvetica'); ?>>Helvetica (sans-serif)</option>
13
- <option value="Tahoma" <?php selected($scheme['font-family'], 'Tahoma'); ?>>Tahoma (sans-serif)</option>
14
- <option value="Trebuchet MS" <?php selected($scheme['font-family'], 'Trebuchet MS'); ?>>Trebuchet MS (sans-serif)</option>
15
- <option value="Times New Roman" <?php selected($scheme['font-family'], 'Times New Roman'); ?>>Times New Roman (serif)</option>
16
- <option value="Georgia" <?php selected($scheme['font-family'], 'Georgia'); ?>>Georgia (serif)</option>
17
- <option value="Garamond" <?php selected($scheme['font-family'], 'Garamond'); ?>>Garamond (serif)</option>
18
- <option value="Courier New" <?php selected($scheme['font-family'], 'Courier New'); ?>>Courier New (monospace)</option>
19
- <option value="Brush Script MT" <?php selected($scheme['font-family'], 'Brush Script MT'); ?>>Brush Script MT (cursive)</option>
20
- <option value="Calibri" <?php selected($scheme['font-family'], 'Calibri'); ?>>Calibri (sans-serif)</option>
21
- </select>
22
- </td>
23
- </tr>
24
- <tr>
25
- <th scope="row"><?php esc_html_e('Font Size', 'wp-whatsapp-chat'); ?></th>
26
- <td>
27
- <input placeholder="<?php esc_html_e('In pixels', 'wp-whatsapp-chat'); ?>" type="number" name="font-size" value="<?php echo esc_attr($scheme['font-size']); ?>" />
28
- </td>
29
- </tr>
30
- <tr>
31
- <th scope="row"><?php esc_html_e('Background', 'wp-whatsapp-chat'); ?></th>
32
- <td>
33
- <input class="qlwapp-color-field" type="text" name="brand" value="<?php echo esc_attr($scheme['brand']); ?>" />
34
- </td>
35
- </tr>
36
- <tr>
37
- <th scope="row"><?php esc_html_e('Color', 'wp-whatsapp-chat'); ?></th>
38
- <td>
39
- <input class="qlwapp-color-field" type="text" name="text" value="<?php echo esc_attr($scheme['text']); ?>" />
40
- </td>
41
- </tr>
42
- <tr class="qlwapp-premium-field">
43
- <th scope="row"><?php esc_html_e('Link', 'wp-whatsapp-chat'); ?></th>
44
- <td>
45
- <input class="qlwapp-color-field" type="link" name="link" value="<?php echo esc_attr($scheme['link']); ?>" />
46
- <p class="description hidden"><small><?php esc_html_e('This is a premium feature', 'wp-whatsapp-chat'); ?></small></p>
47
- </td>
48
- </tr>
49
- <tr class="qlwapp-premium-field">
50
- <th scope="row"><?php esc_html_e('Message', 'wp-whatsapp-chat'); ?></th>
51
- <td>
52
- <input class="qlwapp-color-field" type="link" name="message" value="<?php echo esc_attr($scheme['message']); ?>" />
53
- <p class="description hidden"><small><?php esc_html_e('This is a premium feature', 'wp-whatsapp-chat'); ?></small></p>
54
- </td>
55
- </tr>
56
- <tr class="qlwapp-premium-field">
57
- <th scope="row"><?php esc_html_e('Label', 'wp-whatsapp-chat'); ?></th>
58
- <td>
59
- <input class="qlwapp-color-field" type="link" name="label" value="<?php echo esc_attr($scheme['label']); ?>" />
60
- <p class="description hidden"><small><?php esc_html_e('This is a premium feature', 'wp-whatsapp-chat'); ?></small></p>
61
- </td>
62
- </tr>
63
- <tr class="qlwapp-premium-field">
64
- <th scope="row"><?php esc_html_e('Name', 'wp-whatsapp-chat'); ?></th>
65
- <td>
66
- <input class="qlwapp-color-field" type="link" name="name" value="<?php echo esc_attr($scheme['name']); ?>" />
67
- <p class="description hidden"><small><?php esc_html_e('This is a premium feature', 'wp-whatsapp-chat'); ?></small></p>
68
- </td>
69
- </tr>
70
- </tbody>
71
- </table>
72
- <?php wp_nonce_field('qlwapp_save_scheme', 'qlwapp_scheme_form_nonce'); ?>
73
- <p class="submit">
74
- <?php submit_button(esc_html__('Save', 'wp-whatsapp-chat'), 'primary', 'submit', false); ?>
75
- <span class="settings-save-status">
76
- <span class="saved"><?php esc_html_e('Saved successfully!'); ?></span>
77
- <span class="spinner" style="float: none"></span>
78
- </span>
79
- </p>
80
- </form>
81
- </div>
 
 
 
 
 
 
 
 
 
 
 
 
1
  <div class="wrap about-wrap full-width-layout qlwrap">
2
+ <form method="post" id="qlwapp_scheme_form">
3
+ <table class="form-table">
4
+ <tbody>
5
+ <tr>
6
+ <th scope="row"><?php esc_html_e( 'Font Family', 'wp-whatsapp-chat' ); ?></th>
7
+ <td>
8
+ <select placeholder="<?php esc_html_e( 'Web Default', 'wp-whatsapp-chat' ); ?>" name="font-family" value="<?php echo esc_attr( $scheme['font-family'] ); ?>">
9
+ <option value="inherit" <?php selected( $scheme['font-family'], 'inherit' ); ?>><?php esc_html_e( 'Web Default', 'wp-whatsapp-chat' ); ?></option>
10
+ <option value="Arial" <?php selected( $scheme['font-family'], 'Arial' ); ?>>Arial (sans-serif)</option>
11
+ <option value="Verdana" <?php selected( $scheme['font-family'], 'Verdana' ); ?>>Verdana (sans-serif)</option>
12
+ <option value="Helvetica" <?php selected( $scheme['font-family'], 'Helvetica' ); ?>>Helvetica (sans-serif)</option>
13
+ <option value="Tahoma" <?php selected( $scheme['font-family'], 'Tahoma' ); ?>>Tahoma (sans-serif)</option>
14
+ <option value="Trebuchet MS" <?php selected( $scheme['font-family'], 'Trebuchet MS' ); ?>>Trebuchet MS (sans-serif)</option>
15
+ <option value="Times New Roman" <?php selected( $scheme['font-family'], 'Times New Roman' ); ?>>Times New Roman (serif)</option>
16
+ <option value="Georgia" <?php selected( $scheme['font-family'], 'Georgia' ); ?>>Georgia (serif)</option>
17
+ <option value="Garamond" <?php selected( $scheme['font-family'], 'Garamond' ); ?>>Garamond (serif)</option>
18
+ <option value="Courier New" <?php selected( $scheme['font-family'], 'Courier New' ); ?>>Courier New (monospace)</option>
19
+ <option value="Brush Script MT" <?php selected( $scheme['font-family'], 'Brush Script MT' ); ?>>Brush Script MT (cursive)</option>
20
+ <option value="Calibri" <?php selected( $scheme['font-family'], 'Calibri' ); ?>>Calibri (sans-serif)</option>
21
+ </select>
22
+ </td>
23
+ </tr>
24
+ <tr>
25
+ <th scope="row"><?php esc_html_e( 'Font Size', 'wp-whatsapp-chat' ); ?></th>
26
+ <td>
27
+ <input placeholder="<?php esc_html_e( 'In pixels', 'wp-whatsapp-chat' ); ?>" type="number" name="font-size" value="<?php echo esc_attr( $scheme['font-size'] ); ?>" />
28
+ </td>
29
+ </tr>
30
+ <tr>
31
+ <th scope="row"><?php esc_html_e( 'Background', 'wp-whatsapp-chat' ); ?></th>
32
+ <td>
33
+ <input class="qlwapp-color-field" type="text" name="brand" value="<?php echo esc_attr( $scheme['brand'] ); ?>" />
34
+ </td>
35
+ </tr>
36
+ <tr>
37
+ <th scope="row"><?php esc_html_e( 'Color', 'wp-whatsapp-chat' ); ?></th>
38
+ <td>
39
+ <input class="qlwapp-color-field" type="text" name="text" value="<?php echo esc_attr( $scheme['text'] ); ?>" />
40
+ </td>
41
+ </tr>
42
+ <tr class="qlwapp-premium-field">
43
+ <th scope="row"><?php esc_html_e( 'Icon Size', 'wp-whatsapp-chat' ); ?></th>
44
+ <td>
45
+ <input placeholder="<?php esc_html_e( 'In pixels', 'wp-whatsapp-chat' ); ?>" type="number" name="icon-size" value="<?php echo esc_attr( $scheme['icon-size'] ); ?>" />
46
+ </td>
47
+ </tr>
48
+ <tr class="qlwapp-premium-field">
49
+ <th scope="row"><?php esc_html_e( 'Icon Font Size', 'wp-whatsapp-chat' ); ?></th>
50
+ <td>
51
+ <input placeholder="<?php esc_html_e( 'In pixels', 'wp-whatsapp-chat' ); ?>" type="number" name="icon-font-size" value="<?php echo esc_attr( $scheme['icon-font-size'] ); ?>" />
52
+ </td>
53
+ </tr>
54
+ <tr class="qlwapp-premium-field">
55
+ <th scope="row"><?php esc_html_e( 'Link', 'wp-whatsapp-chat' ); ?></th>
56
+ <td>
57
+ <input class="qlwapp-color-field" type="link" name="link" value="<?php echo esc_attr( $scheme['link'] ); ?>" />
58
+ <p class="description hidden"><small><?php esc_html_e( 'This is a premium feature', 'wp-whatsapp-chat' ); ?></small></p>
59
+ </td>
60
+ </tr>
61
+ <tr class="qlwapp-premium-field">
62
+ <th scope="row"><?php esc_html_e( 'Message', 'wp-whatsapp-chat' ); ?></th>
63
+ <td>
64
+ <input class="qlwapp-color-field" type="link" name="message" value="<?php echo esc_attr( $scheme['message'] ); ?>" />
65
+ <p class="description hidden"><small><?php esc_html_e( 'This is a premium feature', 'wp-whatsapp-chat' ); ?></small></p>
66
+ </td>
67
+ </tr>
68
+ <tr class="qlwapp-premium-field">
69
+ <th scope="row"><?php esc_html_e( 'Label', 'wp-whatsapp-chat' ); ?></th>
70
+ <td>
71
+ <input class="qlwapp-color-field" type="link" name="label" value="<?php echo esc_attr( $scheme['label'] ); ?>" />
72
+ <p class="description hidden"><small><?php esc_html_e( 'This is a premium feature', 'wp-whatsapp-chat' ); ?></small></p>
73
+ </td>
74
+ </tr>
75
+ <tr class="qlwapp-premium-field">
76
+ <th scope="row"><?php esc_html_e( 'Name', 'wp-whatsapp-chat' ); ?></th>
77
+ <td>
78
+ <input class="qlwapp-color-field" type="link" name="name" value="<?php echo esc_attr( $scheme['name'] ); ?>" />
79
+ <p class="description hidden"><small><?php esc_html_e( 'This is a premium feature', 'wp-whatsapp-chat' ); ?></small></p>
80
+ </td>
81
+ </tr>
82
+ </tbody>
83
+ </table>
84
+ <?php wp_nonce_field( 'qlwapp_save_scheme', 'qlwapp_scheme_form_nonce' ); ?>
85
+ <p class="submit">
86
+ <?php submit_button( esc_html__( 'Save', 'wp-whatsapp-chat' ), 'primary', 'submit', false ); ?>
87
+ <span class="settings-save-status">
88
+ <span class="saved"><?php esc_html_e( 'Saved successfully!' ); ?></span>
89
+ <span class="spinner" style="float: none"></span>
90
+ </span>
91
+ </p>
92
+ </form>
93
+ </div>
readme.txt CHANGED
@@ -6,7 +6,7 @@ Tags: whatsapp, whatsapp business, click to chat, whatsapp chat, whatsapp suppor
6
  Requires at least: 4.6
7
  Requires PHP: 5.6
8
  Tested up to: 6.0
9
- Stable tag: 6.0.9
10
  License: GPLv3
11
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
12
 
@@ -133,6 +133,10 @@ Don't use: +001-(555)1234567
133
 
134
  == Changelog ==
135
 
 
 
 
 
136
  = 6.0.9 =
137
  * Fix. WordPress compatibility
138
 
6
  Requires at least: 4.6
7
  Requires PHP: 5.6
8
  Tested up to: 6.0
9
+ Stable tag: 6.1.0
10
  License: GPLv3
11
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
12
 
133
 
134
  == Changelog ==
135
 
136
+ = 6.1.0 =
137
+ * Fix. WhatsApp premium compatibility
138
+ * Fix. Styles fixes
139
+
140
  = 6.0.9 =
141
  * Fix. WordPress compatibility
142
 
wp-whatsapp-chat.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: Social Chat
5
  * Description: Social Chat allows your visitors to contact you or your team through WhatsApp chat with a single click.
6
  * Plugin URI: https://quadlayers.com/portfolio/whatsapp-chat/
7
- * Version: 6.0.9
8
  * Author: QuadLayers
9
  * Author URI: https://quadlayers.com
10
  * License: GPLv3
@@ -18,7 +18,7 @@ if ( ! defined( 'ABSPATH' ) ) {
18
  }
19
 
20
  define( 'QLWAPP_PLUGIN_NAME', 'Social Chat' );
21
- define( 'QLWAPP_PLUGIN_VERSION', '6.0.9' );
22
  define( 'QLWAPP_PLUGIN_FILE', __FILE__ );
23
  define( 'QLWAPP_PLUGIN_DIR', __DIR__ . DIRECTORY_SEPARATOR );
24
  define( 'QLWAPP_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );
4
  * Plugin Name: Social Chat
5
  * Description: Social Chat allows your visitors to contact you or your team through WhatsApp chat with a single click.
6
  * Plugin URI: https://quadlayers.com/portfolio/whatsapp-chat/
7
+ * Version: 6.1.0
8
  * Author: QuadLayers
9
  * Author URI: https://quadlayers.com
10
  * License: GPLv3
18
  }
19
 
20
  define( 'QLWAPP_PLUGIN_NAME', 'Social Chat' );
21
+ define( 'QLWAPP_PLUGIN_VERSION', '6.1.0' );
22
  define( 'QLWAPP_PLUGIN_FILE', __FILE__ );
23
  define( 'QLWAPP_PLUGIN_DIR', __DIR__ . DIRECTORY_SEPARATOR );
24
  define( 'QLWAPP_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );