PluginProbe
WANotifier for Forms and Actions / 2.1.2
WANotifier for Forms and Actions v2.1.2
3.1.0 3.0.4 2.7.10 2.7.11 2.7.12 2.7.13 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 3.0.0 3.0.1 3.0.2 3.0.3 trunk 0.1.0 0.1.1 1.0.0 1.0.1 1.0.2 1.0.3 All 66 releases
notifier / includes / classes / class-notifier-frontend.php

class-notifier-frontend.php in WANotifier for Forms and Actions 2.1.2, at includes/classes/class-notifier-frontend.php

33 lines 719 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 *
4 * @package Wa_Notifier
5 */
6 class Notifier_Frontend {
7 /**
8 * Init
9 */
10 public static function init() {
11 add_action( 'wp_footer', array( __CLASS__ , 'display_whatsapp_chat_button' ) );
12 }
13
14 /**
15 * Display Whatsapp chat button.
16 */
17 public static function display_whatsapp_chat_button() {
18 $enable_click_chat = get_option('notifier_ctc_enable');
19 $btn_style = get_option('notifier_ctc_button_style');
20 $click_chat_number = get_option('notifier_ctc_whatsapp_number');
21
22 if(!$btn_style){
23 return;
24 }
25
26 if($enable_click_chat === 'yes' && !empty($click_chat_number)){
27 if($btn_style !== 'default'){
28 include_once NOTIFIER_PATH . 'templates/buttons/'.$btn_style.'.php';
29 }
30 }
31 }
32 }
33