Noptin_Abstract_Integration::add_autosubscribe_integration_option( array $options, string $title = null, string $description = null )
Adds an autosubscribe checkbox
Parameters Parameters
- $options
(array) (Required) An array of Noptin options.
- $title
(string) (Optional) The option title
Default value: null
- $description
(string) (Optional) The option description.
Default value: null
Return Return
(array) an updated array of Noptin options.
Source Source
File: includes/integrations/class-noptin-abstract-integration.php
public function add_autosubscribe_integration_option( $options, $title = null, $description = null ) { if ( is_null( $title ) ) { $title = __( 'Manual Subscription', 'newsletter-optin-box' ); } if ( is_null( $description ) ) { $description = sprintf( __( 'Check to display a subscription checkbox instead of automatically subscribing new %s', 'newsletter-optin-box' ), $this->context ); } $option_name = $this->get_autosubscribe_integration_option_name(); $this->maybe_save_default_value( $option_name, true ); $options[ $option_name ] = array( 'type' => 'checkbox_alt', 'el' => 'input', 'section' => 'integrations', 'label' => $title, 'description' => $description, 'restrict' => $this->get_enable_integration_option_name(), ); return $options; }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
1.2.6 | Introduced. |