Changeset 2496511
- Timestamp:
- 03/16/2021 06:44:21 AM (5 years ago)
- Location:
- woo-free-product-sample/trunk
- Files:
-
- 6 edited
-
admin/class-woo-free-product-sample-admin.php (modified) (1 diff)
-
includes/class-woo-free-product-sample-helper.php (modified) (1 diff)
-
includes/class-woo-free-product-sample.php (modified) (1 diff)
-
public/class-woo-free-product-sample-public.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
-
woo-free-product-sample.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
woo-free-product-sample/trunk/admin/class-woo-free-product-sample-admin.php
r2446008 r2496511 130 130 public function wfps_settings_page() { 131 131 132 $current_user = wp_get_current_user();133 if( ! in_array('administrator', $current_user->roles) ) {134 return;135 }136 137 132 $settings = Woo_Free_Product_Sample_Settings::wfps_setting_fields(); 138 133 return include WFPS_ADMIN_DIR_PATH . 'partials/woo-free-product-sample-settings.php'; -
woo-free-product-sample/trunk/includes/class-woo-free-product-sample-helper.php
r2474210 r2496511 144 144 switch ( self::wfps_product_type() ) { 145 145 case "simple": 146 $button = '<button type="submit" name="simple-add-to-cart" value="'.get_the_ID().'" id="woo-free-sample-button" class="woo-free-sample-button">'.s elf::wfps_button_text().'</button>';146 $button = '<button type="submit" name="simple-add-to-cart" value="'.get_the_ID().'" id="woo-free-sample-button" class="woo-free-sample-button">'.sprintf( esc_html__( '%s', 'woo-free-product-sample' ), self::wfps_button_text() ).'</button>'; 147 147 break; 148 148 case "variable": 149 $button = '<button type="submit" name="variable-add-to-cart" value="'.get_the_ID().'" id="woo-free-sample-button" class="woo-free-sample-button">'.s elf::wfps_button_text().'</button>';149 $button = '<button type="submit" name="variable-add-to-cart" value="'.get_the_ID().'" id="woo-free-sample-button" class="woo-free-sample-button">'.sprintf( esc_html__( '%s', 'woo-free-product-sample' ), self::wfps_button_text() ).'</button>'; 150 150 break; 151 151 default: -
woo-free-product-sample/trunk/includes/class-woo-free-product-sample.php
r2474210 r2496511 51 51 $this->version = WFPS_VERSION; 52 52 } else { 53 $this->version = '2.1.1 8';53 $this->version = '2.1.19'; 54 54 } 55 55 $this->plugin_name = 'woo-free-product-sample'; -
woo-free-product-sample/trunk/public/class-woo-free-product-sample-public.php
r2461147 r2496511 705 705 } 706 706 707 /** 708 * Woo Reviews Shortcode 709 * 710 * @param none 711 * @return void 712 **/ 713 public function wfps_order_sample( $atts ) 714 { 715 716 // $atts = shortcode_atts( array( 717 // 'product_id' => '', 718 // ), $atts ); 719 720 // $product_id = $atts['product_id']; 721 // $echo =''; 722 // $echo .= '<a href="" class="woo-free-sample-button">'; 723 // $echo .= \Woo_Free_Product_Sample_Helper::wfps_button_text(); 724 // $echo .= '</a>'; 725 726 // return $echo; 727 } 728 707 729 } -
woo-free-product-sample/trunk/readme.txt
r2478349 r2496511 4 4 Tags: free, product, sample, free-sample, free-product-sample, free-sample-product, woocommerce, dokan, e-commerce, ecommerce 5 5 Requires at least: 4.4 6 Tested up to: 5. 66 Tested up to: 5.7 7 7 WC requires at least: 3.1 8 WC tested up to: 4.1.08 WC tested up to: 5.1.0 9 9 Requires PHP: 5.6 10 10 Stable tag: 3.0.1 … … 232 232 = 2.1.18 = 233 233 Remove Add to cart button common class 234 235 = 2.1.19 = 236 Remove admin privilege for setting page -
woo-free-product-sample/trunk/woo-free-product-sample.php
r2478348 r2496511 8 8 * Plugin Name: Free Product Sample for WooCommerce 9 9 * Plugin URI: https://wordpress.org/plugins/woo-free-product-sample 10 * Description: Display an add to cart button in the product detail page to order product as free sample.11 * Version: 2.1.1 810 * Description: It allows customers to order a product sample in a simple way. 11 * Version: 2.1.19 12 12 * Author: TheNextWP 13 * Author URI: https:// www.thenextwp.co13 * Author URI: https://thenextwp.co 14 14 * License: GPL-2.0+ 15 15 * License URI: http://www.gnu.org/licenses/gpl-2.0.txt … … 18 18 * Requires PHP: 5.6 19 19 * Requires at least: 4.4 20 * Tested up to: 5. 620 * Tested up to: 5.7 21 21 * 22 22 * WC requires at least: 3.1 23 * WC tested up to: 4.9.123 * WC tested up to: 5.1.0 24 24 * License: GNU General Public License v3.0 25 25 * License URI: http://www.gnu.org/licenses/gpl-3.0.html … … 31 31 } 32 32 33 define( 'WFPS_VERSION', '2.1.1 8' );33 define( 'WFPS_VERSION', '2.1.19' ); 34 34 define( 'WFPS_MINIMUM_PHP_VERSION', '5.6.0' ); 35 35 define( 'WFPS_MINIMUM_WP_VERSION', '4.4' );
Note: See TracChangeset
for help on using the changeset viewer.