# notifier/3.1.1/includes/classes/class-notifier-frontend.php

WANotifier for Forms and Actions, version 3.1.1. 38 lines.

- Page: https://pluginprobe.com/plugins/notifier/3.1.1/code/includes/classes/class-notifier-frontend.php
- Raw: https://pluginprobe.com/plugins/notifier/3.1.1/raw/includes/classes/class-notifier-frontend.php
- Modified: 2026-03-18T11:56:40+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/notifier/3.1.1/code/includes/classes/class-notifier-frontend.php#L10-L20`.

```php
<?php
if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

/**
 *
 * @package    Wa_Notifier
 */
class Notifier_Frontend {
	/**
	 * Init
	 */
	public static function init() {
        add_action( 'wp_footer', array( __CLASS__ , 'display_whatsapp_chat_button' ) );
	}

	/**
	 * Display Whatsapp chat button.
	 */
	public static function display_whatsapp_chat_button() {
		$enable_click_chat = get_option('notifier_ctc_enable');
		$btn_style = get_option('notifier_ctc_button_style');
		$click_chat_number = get_option('notifier_ctc_whatsapp_number');

		if(!$btn_style){
			return;
		}

		if ( $enable_click_chat === 'yes' && ! empty( $click_chat_number ) ) {
			$valid_styles = array_keys( Notifier_Backend::get_button_styles() );
			if ( $btn_style !== 'default' && in_array( $btn_style, $valid_styles, true ) ) {
				include_once NOTIFIER_PATH . 'templates/buttons/' . $btn_style . '.php';
			}
		}
	}
}

```
