This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Risbl_Admin_Field object | |
$field = Risbl_Admin_Field(); | |
// Add input field | |
echo $field->input([ | |
'id' => 'subscriber', | |
'label' => __('Subscriber', 'risbl-default-page-after-user-login'), | |
'description' => sprintf(__('URL to open after login for %s user role.', 'risbl-default-page-after-user-login'), 'Subscriber'), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Risbl Admin object | |
$setting_page = Risbl_Admin(); | |
// Config and display plugin menu and setting screen | |
$setting_page->config([ | |
'parent_admin' => 'index.php', | |
'parent_admin_slug' => 'index.php', | |
'page_title' => __('Login Redirect', 'risbl-default-page-after-user-login'), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
const FORMULAS_START_CHARACTERS = [ '=', '-', '+', '@', "\t", "\r" ]; | |
public function write( $data, $columns ) { | |
$is_test_mode_off = ! defined( 'AAL_TESTMODE' ) || ( defined( 'AAL_TESTMODE' ) && ! AAL_TESTMODE ); | |
if ( $is_test_mode_off ) { | |
header( 'Content-type: text/csv' ); | |
header( 'Content-Disposition: attachment; filename="activity-log-export.csv"' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function write( $data, $columns ) { | |
$is_test_mode_off = ! defined( 'AAL_TESTMODE' ) || ( defined( 'AAL_TESTMODE' ) && ! AAL_TESTMODE ); | |
if ( $is_test_mode_off ) { | |
header( 'Content-type: text/csv' ); | |
header( 'Content-Disposition: attachment; filename="activity-log-export.csv"' ); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$style = isset( $settings['pricing_table_style'] ) ? $settings['pricing_table_style'] : 'style-1'; | |
if (!in_array($style, array('style-1', 'style-2', 'style-3', 'style-4'))) { | |
$style = 'style-1'; | |
} | |
?> | |
<div <?php echo $element->get_render_attribute_string( 'pricing_attr' ) ?>> | |
<div <?php echo $element->get_render_attribute_string( 'inner_attr' ) ?>> | |
<?php ube_get_template( "elements/pricing-table/{$style}.php", array( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$style = isset( $settings['pricing_table_style'] ) ? $settings['pricing_table_style'] : 'style-1'; | |
?> | |
<div <?php echo $element->get_render_attribute_string( 'pricing_attr' ) ?>> | |
<div <?php echo $element->get_render_attribute_string( 'inner_attr' ) ?>> | |
<?php ube_get_template( "elements/pricing-table/{$style}.php", array( | |
'element' => $element, | |
'settings' => $settings, | |
) ); ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function file_download() { | |
if ( !is_admin() || !is_user_logged_in() ) | |
return; | |
if ( isset($_GET['page']) && isset($_GET['download']) ) { | |
if ( $_GET['page'] !== $this->menu_base ) | |
return; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function file_download() { | |
if ( !is_admin() || !is_user_logged_in() ) | |
return; | |
if ( isset($_GET['page']) && isset($_GET['download']) ) { | |
if ( $_GET['page'] !== $this->menu_base ) | |
return; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$allowed_subpage = array('dashboard', 'profile', 'settings'); | |
if ( Input::has( 'sub_page' ) ) { | |
$sub_page = Input::get( 'sub_page' ); | |
if ( in_array( $sub_page, $allowed, true ) ) { | |
include_once tutor()->path . "views/pages/{$sub_page}.php"; | |
return; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if ( Input::has( 'sub_page' ) ) { | |
$sub_page = Input::get( 'sub_page' ); | |
include_once tutor()->path . "views/pages/{$sub_page}.php"; | |
return; | |
} |
NewerOlder