forked from litespeedtech/lscache_wp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwoocommerce.content.tpl.php
83 lines (73 loc) · 3.38 KB
/
woocommerce.content.tpl.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<?php
namespace LiteSpeed\Thirdparty;
defined( 'WPINC' ) || exit;
use \LiteSpeed\API;
use \LiteSpeed\Doc;
use \LiteSpeed\Admin_Display;
?>
<div data-litespeed-layout='woocommerce'>
<h3 class="litespeed-title-short">
<?php echo __( 'WooCommerce Settings', 'litespeed-cache' ); ?>
<?php Doc::learn_more( 'https://docs.litespeedtech.com/lscache/lscwp/cache/#woocommerce-tab' ); ?>
</h3>
<div class="litespeed-callout notice notice-warning inline">
<h4><?php echo __( 'NOTICE:', 'litespeed-cache' ); ?></h4>
<p><?php echo __( 'After verifying that the cache works in general, please test the cart.', 'litespeed-cache' ); ?></p>
<p><?php echo sprintf( __( 'To test the cart, visit the <a %s>FAQ</a>.', 'litespeed-cache' ), 'href="https://docs.litespeedtech.com/lscache/lscwp/installation/#testing" target="_blank"' ); ?></p>
</div>
<table class="wp-list-table striped litespeed-table"><tbody>
<tr>
<th>
<?php $id = self::O_UPDATE_INTERVAL; ?>
<?php echo __( 'Product Update Interval', 'litespeed-cache' ); ?>
</th>
<td>
<?php
$options = array(
self::O_PQS_CS => __( 'Purge product on changes to the quantity or stock status.', 'litespeed-cache' ) . ' ' . __( 'Purge categories only when stock status changes.', 'litespeed-cache' ),
self::O_PS_CS => __( 'Purge product and categories only when the stock status changes.', 'litespeed-cache' ),
self::O_PS_CN => __( 'Purge product only when the stock status changes.', 'litespeed-cache' ) . ' ' . __( 'Do not purge categories on changes to the quantity or stock status.', 'litespeed-cache' ),
self::O_PQS_CQS => __( 'Always purge both product and categories on changes to the quantity or stock status.', 'litespeed-cache' ),
);
$conf = (int) apply_filters( 'litespeed_conf', $id );
foreach ( $options as $k => $v ) :
$checked = (int) $k === $conf ? ' checked ' : '';
?>
<?php do_action( 'litespeed_setting_enroll', $id ); ?>
<div class='litespeed-radio-row'>
<input type='radio' autocomplete='off' name='<?php echo $id; ?>' id='conf_<?php echo $id; ?>_<?php echo $k; ?>' value='<?php echo $k; ?>' <?php echo $checked; ?> />
<label for='conf_<?php echo $id; ?>_<?php echo $k; ?>'><?php echo $v; ?></label>
</div>
<?php endforeach; ?>
<div class="litespeed-desc">
<?php echo __( 'Determines how changes in product quantity and product stock status affect product pages and their associated category pages.', 'litespeed-cache' ); ?>
</div>
</td>
</tr>
<tr>
<th>
<?php $id = self::O_SHOP_FRONT_TTL; ?>
<?php echo __( 'Use Front Page TTL for the Shop Page', 'litespeed-cache' ); ?>
</th>
<td>
<?php do_action( 'litespeed_build_switch', $id ); ?>
<div class="litespeed-desc">
<?php echo __( 'Checking this option will force the shop page to use the front page TTL setting.', 'litespeed-cache' ); ?>
<?php echo sprintf( __( 'For example, if the homepage for the site is located at %1$s, the shop page may be located at %2$s.', 'litespeed-cache' ), 'https://www.EXAMPLE.com', 'https://www.EXAMPLE.com/shop' ); ?>
</div>
</td>
</tr>
<tr>
<th>
<?php $id = self::O_WOO_CACHE_CART; ?>
<?php echo __( 'Privately Cache Cart', 'litespeed-cache' ); ?>
</th>
<td>
<?php do_action( 'litespeed_build_switch', $id ); ?>
<div class="litespeed-desc">
<?php echo __( 'Privately cache cart when not empty.', 'litespeed-cache' ); ?>
</div>
</td>
</tr>
</tbody></table>
</div>