Changeset 3425964
- Timestamp:
- 12/23/2025 08:45:43 AM (2 months ago)
- Location:
- wc-affiliate/trunk
- Files:
-
- 10 edited
-
assets/css/admin.css (modified) (5 diffs)
-
assets/img/banner-section/discount.gif (modified) (previous)
-
readme.txt (modified) (2 diffs)
-
src/Admin.php (modified) (4 diffs)
-
src/Helper.php (modified) (2 diffs)
-
src/Settings.php (modified) (2 diffs)
-
vendor/composer/installed.php (modified) (2 diffs)
-
views/admin/affiliate-reg-form/affiliate-reg-form.php (modified) (1 diff)
-
views/admin/menus/summary.php (modified) (1 diff)
-
wc-affiliate.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wc-affiliate/trunk/assets/css/admin.css
r3392352 r3425964 3882 3882 3883 3883 3884 /* BFCMdeals notice */3884 /* Year End deals notice */ 3885 3885 [data-notice-id="wc-affiliate-bfcm-deals-campaign-7-dec"] { 3886 3886 border-left-color: #438ffe; … … 3893 3893 } 3894 3894 3895 .wc-affiliate-bfcm-deals-notice . bfcm-content .title {3895 .wc-affiliate-bfcm-deals-notice .year-end-content .title { 3896 3896 color: #3c434a; 3897 3897 font-size: 20px; … … 3900 3900 } 3901 3901 3902 .wc-affiliate-bfcm-deals-notice . bfcm-content .description {3902 .wc-affiliate-bfcm-deals-notice .year-end-content .description { 3903 3903 color: #3c434a; 3904 3904 font-size: 14px; … … 3906 3906 } 3907 3907 3908 .wc-affiliate-bfcm-deals-notice . bfcm-content a {3908 .wc-affiliate-bfcm-deals-notice .year-end-content a { 3909 3909 display: inline-block; 3910 3910 color: #2271b1; … … 3917 3917 } 3918 3918 3919 .wc-affiliate-bfcm-deals-notice . bfcm-content a:hover {3919 .wc-affiliate-bfcm-deals-notice .year-end-content a:hover { 3920 3920 text-decoration: underline; 3921 3921 } -
wc-affiliate/trunk/readme.txt
r3419683 r3425964 4 4 Tags: woocommerce affiliate, affiliate management, woocommerce commission, affiliate marketing, affiliate program 5 5 Requires at least: 6.0 6 Tested up to: 6. 8.37 Stable tag: 2.1 56 Tested up to: 6.9 7 Stable tag: 2.16 8 8 Requires PHP: 7.4 9 9 License: GPLv2 or later … … 192 192 == Changelog == 193 193 194 = v2.16 - 2025-12-23 = 195 196 - [added] Added a new notice for the Year End sale campaign. 197 194 198 = v2.15 - 2025-12-1 = 199 195 200 - [imp] Add functionality to allow or disallow external affiliate URL generation. 196 201 - [imp] Add functionality to show referred by in the user review screen. 197 202 198 203 = v2.14 - 2025-10-13 = 204 199 205 - [fix] fix undefined function issue in affiliate login form. 200 206 -
wc-affiliate/trunk/src/Admin.php
r3392352 r3425964 391 391 392 392 public function wc_affiliate_sale_notice() { 393 $is_bfcm_campaign_active = apply_filters( 'is_bfcm_campaign_active', false ); 394 395 if ( $is_bfcm_campaign_active ) { 393 $is_year_end_campaign_active = apply_filters( 'is_year_end_campaign_active', false ); 394 $is_wp_dashboard = is_admin() && basename( $_SERVER['PHP_SELF'] ) === 'index.php'; 395 396 if ( $is_year_end_campaign_active ) { 396 397 return; 397 398 } 398 399 399 400 if ( ! defined( 'WCAFFILIATE_PRO' ) ) { 400 $notice_id = 'wc-affiliate- bfcm-deals-campaign-7-dec';401 $notice_id = 'wc-affiliate-year-end-deals-campaign-21-dec'; 401 402 $discount_img = WOOLEMENTOR_ASSETS . '/img/banner-section/discount.gif'; 402 $url = 'https://wcaffiliate.com/pricing/?utm_source=wpdashboard&utm_medium=banner&utm_campaign=bfcm';403 404 $dismissed_time = get_option( 'wc-affiliate- bfcm-deals-campaign-7-dec_dismissed' );403 $url = $is_wp_dashboard ? 'https://wcaffiliate.com/pricing/?utm_source=wpdashboard&utm_medium=banner&utm_campaign=year-end' : 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=dashboard&utm_campaign=year-end'; 404 405 $dismissed_time = get_option( 'wc-affiliate-year-end-deals-campaign-21-dec_dismissed' ); 405 406 $current_time = date_i18n( 'U' ); 406 $ seven_days = 7* DAY_IN_SECONDS;407 408 if( $dismissed_time !== false && $current_time <= ( $dismissed_time + $ seven_days ) ) {407 $five_days = 5 * DAY_IN_SECONDS; 408 409 if( $dismissed_time !== false && $current_time <= ( $dismissed_time + $five_days ) ) { 409 410 return; 410 411 } 411 412 412 413 $sale_notice = new Notice( $notice_id ); 413 $start_timestamp = strtotime( '2025-1 1-923:59:59' );414 $expiry_timestamp = strtotime( '202 5-12-723:59:59' );414 $start_timestamp = strtotime( '2025-12-20 23:59:59' ); 415 $expiry_timestamp = strtotime( '2026-1-10 23:59:59' ); 415 416 $sale_notice->set_start_time( $start_timestamp ); 416 417 $sale_notice->set_expiry( $expiry_timestamp ); … … 422 423 </div> 423 424 424 <div class=" bfcm-content">425 <p class="title">' . __( ' WC Affiliate BFCM Sale is Live!', 'wc-affiliate' ) . '</p>426 <p class="description">' . __( 'Enjoy up to 70% off WC Affiliate Pro and grow your revenue by running your own high-converting affiliate program!', 'wc-affiliate' ) . '</p>425 <div class="year-end-content"> 426 <p class="title">' . __( 'Celebrate the Year-End with WC Affiliate!', 'wc-affiliate' ) . '</p> 427 <p class="description">' . __( 'Enjoy a flat 50% off WC Affiliate Pro and set up a smarter affiliate program to grow your revenue.', 'wc-affiliate' ) . '</p> 427 428 <a href="' . esc_url( $url ) . '" class="notice-cta-button" data-id="' . esc_attr( $notice_id ) . '" target="_blank"> 428 ' . __( 'Save 70% Now', 'wc-affiliate' ) . '429 ' . __( 'Save 50% Now', 'wc-affiliate' ) . ' 429 430 </a> 430 431 </div> … … 436 437 $sale_notice->render(); 437 438 438 add_filter( 'is_ bfcm_campaign_active', '__return_true');439 add_filter( 'is_year_end_campaign_active', '__return_true'); 439 440 } 440 441 } … … 917 918 if ( ! in_array( 'wc-affiliate-pro/wc-affiliate-pro.php', $active_plugins ) ) { 918 919 ?> 919 <a class="pro-btn" target="_blank" href="<?php echo esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign= bfcm' ); ?>"><?php esc_html_e( 'Enjoy Pro Features', 'wc-affiliate' ); ?></a>920 <a class="pro-btn" target="_blank" href="<?php echo esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign=year-end' ); ?>"><?php esc_html_e( 'Enjoy Pro Features', 'wc-affiliate' ); ?></a> 920 921 <?php } ?> 921 922 </div> -
wc-affiliate/trunk/src/Helper.php
r3392352 r3425964 210 210 public static function pro_notice( $preview = '', $text = '', $show_note = true ) { 211 211 // Translators: %s is the URL to the WC Affiliate Pro upgrade page. 212 $text = $text != '' ? esc_html( $text ) : sprintf( __( 'This is a premium feature. Upgrade to <a href="%s" target="_blank">WC Affiliate Pro</a> to unlock this feature.', 'wc-affiliate' ), 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign= bfcm' );212 $text = $text != '' ? esc_html( $text ) : sprintf( __( 'This is a premium feature. Upgrade to <a href="%s" target="_blank">WC Affiliate Pro</a> to unlock this feature.', 'wc-affiliate' ), 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign=year-end' ); 213 213 214 214 $title = __( 'Admin Notice', 'wc-affiliate' ); … … 247 247 <div class='wsp-footer'> 248 248 <a target='_blank' class='wsp-button button button-primary' href='" . esc_url( $redirect_url ) . "'>" . __( 'Learn More', 'wc-affiliate' ) . "</a> 249 <a target='_blank' href='" . esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign= bfcm' ) . "' class='wsp-button button button-primary wf-feature-unlock-btn'>249 <a target='_blank' href='" . esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign=year-end' ) . "' class='wsp-button button button-primary wf-feature-unlock-btn'> 250 250 <span class='dashicons dashicons-lock'></span> " . esc_html__( 'Unlock This Feature', 'wc-affiliate' ) . " 251 251 </a> -
wc-affiliate/trunk/src/Settings.php
r3407472 r3425964 838 838 'id' => "{$this->slug}-pro", 839 839 'parent' => $this->slug, 840 'label' => __( '<span style="font-weight: bold;"> BFCM - Save up to 70%</span>', 'wc-affiliate' ),840 'label' => __( '<span style="font-weight: bold;">Celebrate Year-End with 50% Off</span>', 'wc-affiliate' ), 841 841 'title' => __( 'Sale - Flat 50% OFF', 'wc-affiliate' ), 842 842 'icon' => 'dashicons-chart-line', … … 859 859 global $pagenow; 860 860 if ( $pagenow == 'admin.php' && isset( $_GET['page'] ) && $_GET['page'] == 'wc-affiliate-pro' ) { 861 exit( esc_url( wp_redirect( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign= bfcm' ) ) );861 exit( esc_url( wp_redirect( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign=year-end' ) ) ); 862 862 } 863 863 } -
wc-affiliate/trunk/vendor/composer/installed.php
r3419683 r3425964 2 2 'root' => array( 3 3 'name' => '__root__', 4 'pretty_version' => 'v2.1 5',5 'version' => '2.1 5.0.0',6 'reference' => '6 4433a6ffc2a71d1ecf7fa5de79fca16df52452d',4 'pretty_version' => 'v2.16', 5 'version' => '2.16.0.0', 6 'reference' => '678bfe4d73a09a8bec39d3c38f2b29ff3e061643', 7 7 'type' => 'library', 8 8 'install_path' => __DIR__ . '/../../', … … 12 12 'versions' => array( 13 13 '__root__' => array( 14 'pretty_version' => 'v2.1 5',15 'version' => '2.1 5.0.0',16 'reference' => '6 4433a6ffc2a71d1ecf7fa5de79fca16df52452d',14 'pretty_version' => 'v2.16', 15 'version' => '2.16.0.0', 16 'reference' => '678bfe4d73a09a8bec39d3c38f2b29ff3e061643', 17 17 'type' => 'library', 18 18 'install_path' => __DIR__ . '/../../', -
wc-affiliate/trunk/views/admin/affiliate-reg-form/affiliate-reg-form.php
r3392352 r3425964 16 16 <div class="wsp-footer"> 17 17 <a target="_blank" class="wsp-button button button-primary" href="<?php echo esc_url( 'https://codexpert.io/wc-affiliate/' ); ?>"><?php esc_html_e( 'Learn More', 'wc-affiliate' ); ?></a> 18 <a target="_blank" href="<?php echo esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign= bfcm' ); ?>" class="wsp-button button button-primary wf-feature-unlock-btn">18 <a target="_blank" href="<?php echo esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign=year-end' ); ?>" class="wsp-button button button-primary wf-feature-unlock-btn"> 19 19 <span class="dashicons dashicons-lock"></span> <?php esc_html_e( 'Unlock This Feature', 'wc-affiliate' ); ?> 20 20 </a> -
wc-affiliate/trunk/views/admin/menus/summary.php
r3392352 r3425964 81 81 if ( ! in_array( 'wc-affiliate-pro/wc-affiliate-pro.php', $active_plugins ) ) { 82 82 ?> 83 <a target="_blank" href="<?php echo esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign= bfcm' ); ?>" class="wf-summary-button pro-btn">83 <a target="_blank" href="<?php echo esc_url( 'https://wcaffiliate.com/pricing/?utm_source=inplugin&utm_medium=button&utm_campaign=year-end' ); ?>" class="wf-summary-button pro-btn"> 84 84 <?php esc_html_e( 'Enjoy Pro Features', 'wc-affiliate' ); ?> 85 85 </a> 86 86 <?php } ?> 87 <a target="_blank" href="https:// help.codexpert.io/docs/wc-affiliate" class="wf-summary-button">87 <a target="_blank" href="https://wcaffiliate.com/docs/" class="wf-summary-button"> 88 88 <?php esc_html_e( 'Documentation', 'wc-affiliate' ); ?> 89 89 </a> -
wc-affiliate/trunk/wc-affiliate.php
r3419683 r3425964 6 6 * Author: Codexpert 7 7 * Author URI: https://codexpert.io/?utm_campaign=author-uri 8 * Version: 2.1 58 * Version: 2.16 9 9 * Text Domain: wc-affiliate 10 10 * Domain Path: /languages
Note: See TracChangeset
for help on using the changeset viewer.