apache
wp-content
mu-plugins
plugins
activitypub
audioigniter
authldap
companion-auto-update
gitium
gp-premium
jetpack-protect
menu-icons
simple-local-avatars
smtp-mailer
two-factor
w3-total-cache
extension-example
inc
ini
languages
lib
pub
vendor
wp-content
Base_Page_Settings.php
BrowserCache_ConfigLabels.php
BrowserCache_Core.php
BrowserCache_Environment.php
BrowserCache_Environment_Apache.php
BrowserCache_Environment_LiteSpeed.php
BrowserCache_Environment_Nginx.php
BrowserCache_Page.php
BrowserCache_Page_View_QuickReference.php
BrowserCache_Page_View_SectionSecurity.php
BrowserCache_Plugin.php
BrowserCache_Plugin_Admin.php
Cache.php
CacheFlush.php
CacheFlush_Locally.php
CacheGroups_Plugin_Admin.php
CacheGroups_Plugin_Admin_View.js
CacheGroups_Plugin_Admin_View.php
Cache_Apc.php
Cache_Apcu.php
Cache_Base.php
Cache_Eaccelerator.php
Cache_File.php
Cache_File_Cleaner.php
Cache_File_Cleaner_Generic.php
Cache_File_Cleaner_Generic_HardDelete.php
Cache_File_Generic.php
Cache_Memcache.php
Cache_Memcached.php
Cache_Memcached_Stats.php
Cache_Nginx_Memcached.php
Cache_Redis.php
Cache_Wincache.php
Cache_Xcache.php
CdnEngine.php
CdnEngine_Azure.php
CdnEngine_Base.php
CdnEngine_CloudFront.php
CdnEngine_Ftp.php
CdnEngine_GoogleDrive.php
CdnEngine_Mirror.php
CdnEngine_Mirror_Akamai.php
CdnEngine_Mirror_Att.php
CdnEngine_Mirror_CloudFront.php
CdnEngine_Mirror_Cotendo.php
CdnEngine_Mirror_Edgecast.php
CdnEngine_Mirror_Highwinds.php
CdnEngine_Mirror_LimeLight.php
CdnEngine_Mirror_RackSpaceCdn.php
CdnEngine_Mirror_StackPath.php
CdnEngine_Mirror_StackPath2.php
CdnEngine_RackSpaceCloudFiles.php
CdnEngine_S3.php
CdnEngine_S3_Compatible.php
Cdn_AdminActions.php
Cdn_AdminNotes.php
Cdn_CacheFlush.php
Cdn_ConfigLabels.php
Cdn_Core.php
Cdn_Core_Admin.php
Cdn_Environment.php
Cdn_Environment_LiteSpeed.php
Cdn_Environment_Nginx.php
Cdn_GeneralPage_View.php
Cdn_GoogleDrive_AdminActions.php
Cdn_GoogleDrive_Page.php
Cdn_GoogleDrive_Page_View.js
Cdn_GoogleDrive_Page_View.php
Cdn_GoogleDrive_Popup_AuthReturn.php
Cdn_GoogleDrive_Popup_AuthReturn_View.php
Cdn_Highwinds_Api.php
Cdn_Highwinds_Page.php
Cdn_Highwinds_Page_View.js
Cdn_Highwinds_Page_View.php
Cdn_Highwinds_Popup.php
Cdn_Highwinds_Popup_View_ConfigureCnamesForm.php
Cdn_Highwinds_Popup_View_Intro.php
Cdn_Highwinds_Popup_View_SelectHost.php
Cdn_Highwinds_Widget.php
Cdn_Highwinds_Widget_View.css
Cdn_Highwinds_Widget_View.js
Cdn_Highwinds_Widget_View.php
Cdn_Highwinds_Widget_View_NotConfigured.php
Cdn_LimeLight_Page.php
Cdn_LimeLight_Page_View.js
Cdn_LimeLight_Page_View.php
Cdn_LimeLight_Popup.php
Cdn_LimeLight_Popup_View_Intro.php
Cdn_LimeLight_Popup_View_Success.php
Cdn_Page.php
Cdn_Page_View_Fsd_HeaderActions.php
Cdn_Page_View_Header.php
Cdn_Plugin.php
Cdn_Plugin_Admin.php
Cdn_RackSpaceCdn_AdminActions.php
Cdn_RackSpaceCdn_Page.php
Cdn_RackSpaceCdn_Page_View.js
Cdn_RackSpaceCdn_Page_View.php
Cdn_RackSpaceCdn_Popup.php
Cdn_RackSpaceCdn_Popup_View_ConfigureDomains.php
Cdn_RackSpaceCdn_Popup_View_Intro.php
Cdn_RackSpaceCdn_Popup_View_Regions.php
Cdn_RackSpaceCdn_Popup_View_Service_Actualize.php
Cdn_RackSpaceCdn_Popup_View_Service_Create.php
Cdn_RackSpaceCdn_Popup_View_Service_Created.php
Cdn_RackSpaceCdn_Popup_View_Services.php
Cdn_RackSpaceCloudFiles_Page.php
Cdn_RackSpaceCloudFiles_Page_View.js
Cdn_RackSpaceCloudFiles_Page_View.php
Cdn_RackSpaceCloudFiles_Popup.php
Cdn_RackSpaceCloudFiles_Popup_View_Containers.php
Cdn_RackSpaceCloudFiles_Popup_View_Intro.php
Cdn_RackSpaceCloudFiles_Popup_View_Regions.php
Cdn_RackSpace_Api_CaCert-example.pem
Cdn_RackSpace_Api_Cdn.php
Cdn_RackSpace_Api_CloudFiles.php
Cdn_RackSpace_Api_CloudFilesCdn.php
Cdn_RackSpace_Api_Tokens.php
Cdn_StackPath2_Api.php
Cdn_StackPath2_Page.php
Cdn_StackPath2_Page_View.js
Cdn_StackPath2_Page_View.php
Cdn_StackPath2_Popup.php
Cdn_StackPath2_Popup_View_Intro.php
Cdn_StackPath2_Popup_View_Sites.php
Cdn_StackPath2_Popup_View_Stacks.php
Cdn_StackPath2_Popup_View_Success.php
Cdn_StackPath2_Widget.php
Cdn_StackPath2_Widget_View.css
Cdn_StackPath2_Widget_View.js
Cdn_StackPath2_Widget_View_Authorized.php
Cdn_StackPath2_Widget_View_Unauthorized.php
Cdn_StackPath_Api.php
Cdn_StackPath_Page.php
Cdn_StackPath_Page_View.js
Cdn_StackPath_Page_View.php
Cdn_StackPath_Popup.php
Cdn_StackPath_Popup_View_Intro.php
Cdn_StackPath_Popup_View_Success.php
Cdn_StackPath_Popup_View_Zone.php
Cdn_StackPath_Popup_View_Zones.php
Cdn_StackPath_Widget.php
Cdn_StackPath_Widget_View.css
Cdn_StackPath_Widget_View.js
Cdn_StackPath_Widget_View_Authorized.php
Cdn_StackPath_Widget_View_Unauthorized.php
Cdn_Util.php
Cdnfsd_CacheFlush.php
Cdnfsd_CloudFront_Engine.php
Cdnfsd_CloudFront_Page.php
Cdnfsd_CloudFront_Page_View.js
Cdnfsd_CloudFront_Page_View.php
Cdnfsd_CloudFront_Popup.php
Cdnfsd_CloudFront_Popup_View_Distribution.php
Cdnfsd_CloudFront_Popup_View_Distributions.php
Cdnfsd_CloudFront_Popup_View_Intro.php
Cdnfsd_CloudFront_Popup_View_Success.php
Cdnfsd_Core.php
Cdnfsd_GeneralPage_View.php
Cdnfsd_LimeLight_Api.php
Cdnfsd_LimeLight_Engine.php
Cdnfsd_LimeLight_Page.php
Cdnfsd_LimeLight_Page_View.js
Cdnfsd_LimeLight_Page_View.php
Cdnfsd_LimeLight_Popup.php
Cdnfsd_LimeLight_Popup_View_Intro.php
Cdnfsd_LimeLight_Popup_View_Success.php
Cdnfsd_Page_View_Header.php
Cdnfsd_Plugin.php
Cdnfsd_Plugin_Admin.php
Cdnfsd_StackPath2_Engine.php
Cdnfsd_StackPath2_Page.php
Cdnfsd_StackPath2_Page_View.js
Cdnfsd_StackPath2_Page_View.php
Cdnfsd_StackPath2_Popup.php
Cdnfsd_StackPath2_Popup_View_Intro.php
Cdnfsd_StackPath2_Popup_View_Sites.php
Cdnfsd_StackPath2_Popup_View_Stacks.php
Cdnfsd_StackPath2_Popup_View_Success.php
Cdnfsd_StackPath_Engine.php
Cdnfsd_StackPath_Page.php
Cdnfsd_StackPath_Page_View.js
Cdnfsd_StackPath_Page_View.php
Cdnfsd_StackPath_Popup.php
Cdnfsd_StackPath_Popup_View_Intro.php
Cdnfsd_StackPath_Popup_View_Success.php
Cdnfsd_StackPath_Popup_View_Zone.php
Cdnfsd_StackPath_Popup_View_Zones.php
Cdnfsd_TransparentCDN_Engine.php
Cdnfsd_TransparentCDN_Page.php
Cdnfsd_TransparentCDN_Page_View.js
Cdnfsd_TransparentCDN_Page_View.php
Cdnfsd_Util.php
Cli.php
Config.php
ConfigCache.php
ConfigCompiler.php
ConfigDbStorage.php
ConfigKeys.php
ConfigState.php
ConfigStateNote.php
ConfigUtil.php
DbCache_ConfigLabels.php
DbCache_Core.php
DbCache_Environment.php
DbCache_Page.php
DbCache_Plugin.php
DbCache_Plugin_Admin.php
DbCache_Wpdb.php
DbCache_WpdbBase.php
DbCache_WpdbInjection.php
DbCache_WpdbInjection_QueryCaching.php
DbCache_WpdbLegacy.php
DbCache_WpdbNew.php
Dispatcher.php
Enterprise_CacheFlush_MakeSnsEvent.php
Enterprise_Dbcache_WpdbInjection_Cluster.php
Enterprise_SnsBase.php
Enterprise_SnsServer.php
Extension_Amp_Page_View.php
Extension_Amp_Plugin.php
Extension_Amp_Plugin_Admin.php
Extension_CloudFlare_AdminActions.php
Extension_CloudFlare_Api.php
Extension_CloudFlare_Cdn_Page_View.php
Extension_CloudFlare_GeneralPage_View.php
Extension_CloudFlare_Page.php
Extension_CloudFlare_Page_View.js
Extension_CloudFlare_Page_View.php
Extension_CloudFlare_Plugin.php
Extension_CloudFlare_Plugin_Admin.php
Extension_CloudFlare_Popup.php
Extension_CloudFlare_Popup_View_Intro.php
Extension_CloudFlare_Popup_View_Zones.php
Extension_CloudFlare_SettingsForUi.php
Extension_CloudFlare_View_Dashboard.js
Extension_CloudFlare_Widget.php
Extension_CloudFlare_Widget_Logo.png
Extension_CloudFlare_Widget_View.css
Extension_CloudFlare_Widget_View.php
Extension_FragmentCache_Api.php
Extension_FragmentCache_Core.php
Extension_FragmentCache_Environment.php
Extension_FragmentCache_GeneralPage.php
Extension_FragmentCache_GeneralPage_View.php
Extension_FragmentCache_Page.php
Extension_FragmentCache_Page_View.php
Extension_FragmentCache_Plugin.php
Extension_FragmentCache_Plugin_Admin.php
Extension_FragmentCache_WpObjectCache.php
Extension_Genesis_Page.php
Extension_Genesis_Page_View.php
Extension_Genesis_Plugin.php
Extension_Genesis_Plugin_Admin.php
Extension_ImageService_Api.php
Extension_ImageService_Cron.php
Extension_ImageService_Environment.php
Extension_ImageService_Page_View.php
Extension_ImageService_Plugin.php
Extension_ImageService_Plugin_Admin.css
Extension_ImageService_Plugin_Admin.js
Extension_ImageService_Plugin_Admin.php
Extension_NewRelic_AdminActions.php
Extension_NewRelic_AdminNotes.php
Extension_NewRelic_Api.php
Extension_NewRelic_Core.php
Extension_NewRelic_GeneralPage.php
Extension_NewRelic_GeneralPage_View.php
Extension_NewRelic_Page.php
Extension_NewRelic_Page_View_Apm.php
Extension_NewRelic_Plugin.php
Extension_NewRelic_Plugin_Admin.php
Extension_NewRelic_Popup.php
Extension_NewRelic_Popup_View.js
Extension_NewRelic_Popup_View_Intro.php
Extension_NewRelic_Popup_View_ListApplications.php
Extension_NewRelic_Service.php
Extension_NewRelic_Widget.php
Extension_NewRelic_Widget_View.css
Extension_NewRelic_Widget_View.js
Extension_NewRelic_Widget_View_Apm.php
Extension_NewRelic_Widget_View_Browser.php
Extension_NewRelic_Widget_View_NotConfigured.php
Extension_Swarmify_AdminActions.php
Extension_Swarmify_Core.php
Extension_Swarmify_Page.php
Extension_Swarmify_Page_View.php
Extension_Swarmify_Plugin.php
Extension_Swarmify_Plugin_Admin.php
Extension_Swarmify_Widget.php
Extension_Swarmify_Widget_View.css
Extension_Swarmify_Widget_View_NotConfigured.php
Extension_WordPressSeo_Plugin.php
Extension_WordPressSeo_Plugin_Admin.php
Extension_Wpml_Plugin.php
Extension_Wpml_Plugin_Admin.php
Extensions_AdminActions.php
Extensions_Page.php
Extensions_Plugin_Admin.php
Extensions_Util.php
FeatureShowcase_Plugin_Admin.php
FeatureShowcase_Plugin_Admin_View.php
Generic_AdminActions_Config.php
Generic_AdminActions_Default.php
Generic_AdminActions_Flush.php
Generic_AdminActions_Test.php
Generic_AdminNotes.php
Generic_ConfigLabels.php
Generic_Environment.php
Generic_Faq.php
Generic_GeneralPage_View_ShowEdge.js
Generic_GeneralPage_View_ShowSupportUs.js
Generic_Page_About.php
Generic_Page_Dashboard.php
Generic_Page_Dashboard_View.css
Generic_Page_General.php
Generic_Page_Install.php
Generic_Page_PurgeLog.php
Generic_Page_PurgeLog_View.php
Generic_Plugin.php
Generic_Plugin_Admin.php
Generic_Plugin_AdminCompatibility.php
Generic_Plugin_AdminNotifications.php
Generic_Plugin_AdminRowActions.php
Generic_Plugin_Admin_View_Faq.php
Generic_Plugin_WidgetForum.php
Generic_Plugin_WidgetNews.php
Generic_WidgetBoldGrid.php
Generic_WidgetBoldGrid_AdminActions.php
Generic_WidgetBoldGrid_Logo.svg
Generic_WidgetBoldGrid_View.js
Generic_WidgetBoldGrid_View.php
Generic_WidgetCommunity.php
Generic_WidgetCommunity_View.php
Generic_WidgetServices.php
Generic_WidgetServices_View.php
Generic_WidgetSpreadTheWord.js
Generic_WidgetSpreadTheWord_Plugin.php
Generic_WidgetSpreadTheWord_View.php
LICENSE
Licensing_AdminActions.php
Licensing_Core.php
Licensing_Plugin_Admin.php
Minify_AutoCss.php
Minify_AutoJs.php
Minify_ConfigLabels.php
Minify_ContentMinifier.php
Minify_Core.php
Minify_Environment.php
Minify_Environment_LiteSpeed.php
Minify_Extract.php
Minify_GeneralPage_View_ShowHelp.js
Minify_GeneralPage_View_ShowHelpForce.js
Minify_HelpPopup_View.php
Minify_MinifiedFileRequestHandler.php
Minify_Page.php
Minify_Plugin.php
Minify_Plugin_Admin.php
Mobile_Base.php
Mobile_Redirect.php
Mobile_Referrer.php
Mobile_UserAgent.php
ModuleStatus.php
ObjectCache_ConfigLabels.php
ObjectCache_Environment.php
ObjectCache_Page.php
ObjectCache_Page_View_PurgeLog.php
ObjectCache_Plugin.php
ObjectCache_Plugin_Admin.php
ObjectCache_WpObjectCache.php
ObjectCache_WpObjectCache_Regular.php
PageSpeed_Api.php
PageSpeed_Data.php
PageSpeed_Instructions.php
PageSpeed_Page.php
PageSpeed_Page_View.css
PageSpeed_Page_View.js
PageSpeed_Page_View.php
PageSpeed_Page_View_FromAPI.php
PageSpeed_Widget.php
PageSpeed_Widget_View.css
PageSpeed_Widget_View.js
PageSpeed_Widget_View.php
PageSpeed_Widget_View_FromApi.php
PgCache_ConfigLabels.php
PgCache_ContentGrabber.php
PgCache_Environment.php
PgCache_Flush.php
PgCache_Page.php
PgCache_Page_View.js
PgCache_Plugin.php
PgCache_Plugin_Admin.php
PgCache_QsExempts.php
Root_AdminActions.php
Root_AdminActivation.php
Root_AdminMenu.php
Root_Environment.php
Root_Loader.php
SetupGuide_Plugin_Admin.php
Support_AdminActions.php
Support_Page.php
Support_Page_View_DoneContent.php
Support_Page_View_PageContent.php
SystemOpCache_AdminActions.php
SystemOpCache_Core.php
SystemOpCache_GeneralPage_View.php
SystemOpCache_Plugin_Admin.php
UsageStatistics_AdminActions.php
UsageStatistics_Core.php
UsageStatistics_GeneralPage.php
UsageStatistics_GeneralPage_View.php
UsageStatistics_Page.php
UsageStatistics_Page_DbRequests_View.php
UsageStatistics_Page_ObjectCacheLog_View.php
UsageStatistics_Page_PageCacheRequests_View.php
UsageStatistics_Page_View.css
UsageStatistics_Page_View.js
UsageStatistics_Page_View.php
UsageStatistics_Page_View_Ad.php
UsageStatistics_Page_View_Disabled.php
UsageStatistics_Page_View_Free.php
UsageStatistics_Page_View_NoDebugMode.php
UsageStatistics_Plugin.php
UsageStatistics_Plugin_Admin.php
UsageStatistics_Source_AccessLog.php
UsageStatistics_Source_DbQueriesLog.php
UsageStatistics_Source_ObjectCacheLog.php
UsageStatistics_Source_PageCacheLog.php
UsageStatistics_Source_Wpdb.php
UsageStatistics_Sources.php
UsageStatistics_Sources_Apc.php
UsageStatistics_Sources_Memcached.php
UsageStatistics_Sources_Redis.php
UsageStatistics_StorageReader.php
UsageStatistics_StorageWriter.php
UsageStatistics_Widget.php
UsageStatistics_Widget_View.js
UsageStatistics_Widget_View.php
UsageStatistics_Widget_View_Disabled.php
UserExperience_DeferScripts_Extension.php
UserExperience_DeferScripts_Mutator.php
UserExperience_DeferScripts_Page_View.php
UserExperience_DeferScripts_Script.js
UserExperience_Emoji_Extension.php
UserExperience_GeneralPage.php
UserExperience_GeneralPage_View.php
UserExperience_LazyLoad_GoogleMaps_GoogleMapsEasy.php
UserExperience_LazyLoad_GoogleMaps_WPGoogleMapPlugin.php
UserExperience_LazyLoad_GoogleMaps_WPGoogleMaps.php
UserExperience_LazyLoad_Mutator.php
UserExperience_LazyLoad_Mutator_Picture.php
UserExperience_LazyLoad_Mutator_Unmutable.php
UserExperience_LazyLoad_Page_View.php
UserExperience_LazyLoad_Plugin.php
UserExperience_OEmbed_Extension.php
UserExperience_Page.php
UserExperience_Page_View.php
UserExperience_Plugin_Admin.php
UserExperience_Plugin_Jquery.php
Util_Activation.php
Util_Admin.php
Util_AttachToActions.php
Util_Bus.php
Util_ConfigLabel.php
Util_Content.php
Util_Debug.php
Util_DebugPurgeLog_Reader.php
Util_Environment.php
Util_Environment_Exception.php
Util_Environment_Exceptions.php
Util_File.php
Util_Http.php
Util_Installed.php
Util_Mime.php
Util_PageSpeed.php
Util_PageUrls.php
Util_Request.php
Util_Rule.php
Util_Theme.php
Util_Ui.php
Util_UsageStatistics.php
Util_Widget.php
Util_WpFile.php
Util_WpFile_FilesystemChmodException.php
Util_WpFile_FilesystemCopyException.php
Util_WpFile_FilesystemMkdirException.php
Util_WpFile_FilesystemModifyException.php
Util_WpFile_FilesystemOperationException.php
Util_WpFile_FilesystemRmException.php
Util_WpFile_FilesystemRmdirException.php
Util_WpFile_FilesystemWriteException.php
Util_WpmuBlogmap.php
Varnish_Flush.php
Varnish_Plugin.php
index.html
press.txt
readme.txt
w3-total-cache-api.php
w3-total-cache-old-php.php
w3-total-cache.php
wp-piwik
wp-webauthn
index.php
themes
upgrade-temp-backup
w3tc-config
index.php
.dbsetup
.gitignore
htaccess
php.ini
342 lines
15 KiB
PHP
342 lines
15 KiB
PHP
<?php
|
|
/**
|
|
* File: CacheGroups_Plugin_Admin_View.php
|
|
*
|
|
* @since 2.1.0
|
|
*
|
|
* @package W3TC
|
|
*
|
|
* @uses $useragent_groups
|
|
* @uses $useragent_themes
|
|
* @uses $referrer_groups
|
|
* @uses $referrer_themes
|
|
* @uses $cookie_groups
|
|
*/
|
|
|
|
namespace W3TC;
|
|
|
|
if ( ! defined( 'W3TC' ) ) {
|
|
die();
|
|
}
|
|
?>
|
|
|
|
<form id="cachegroups_form" action="admin.php?page=<?php echo esc_attr( $this->_page ); ?>" method="post">
|
|
<?php Util_UI::print_control_bar( 'cachegroups_form_control' ); ?>
|
|
|
|
<!-- User Agenet Groups -->
|
|
|
|
<script type="text/javascript">/*<![CDATA[*/
|
|
var mobile_themes = {};
|
|
<?php foreach ( $useragent_themes as $theme_key => $theme_name ) : ?>
|
|
mobile_themes['<?php echo esc_attr( addslashes( $theme_key ) ); ?>'] = '<?php echo esc_html( addslashes( $theme_name ) ); ?>';
|
|
<?php endforeach; ?>
|
|
/*]]>*/</script>
|
|
|
|
<div class="metabox-holder">
|
|
<?php Util_Ui::postbox_header( esc_html__( 'Manage User Agent Groups', 'w3-total-cache' ), '', 'manage-uag' ); ?>
|
|
<p>
|
|
<input id="mobile_add" type="button" class="button"
|
|
<?php disabled( $useragent_groups['disabled'] ); ?>
|
|
value="<?php esc_html_e( 'Create a group', 'w3-total-cache' ); ?>" />
|
|
<?php esc_html_e( 'of user agents by specifying names in the user agents field. Assign a set of user agents to use a specific theme, redirect them to another domain or if an existing mobile plugin is active, create user agent groups to ensure that a unique cache is created for each user agent group. Drag and drop groups into order (if needed) to determine their priority (top -> down).', 'w3-total-cache' ); ?>
|
|
</p>
|
|
|
|
<ul id="mobile_groups">
|
|
<?php
|
|
$index = 0;
|
|
|
|
foreach ( $useragent_groups['value'] as $group => $group_config ) :
|
|
$index++;
|
|
?>
|
|
<li id="mobile_group_<?php echo esc_attr( $group ); ?>">
|
|
<table class="form-table">
|
|
<tr>
|
|
<th>
|
|
<?php esc_html_e( 'Group name:', 'w3-total-cache' ); ?>
|
|
</th>
|
|
<td>
|
|
<span class="mobile_group_number"><?php echo esc_attr( $index ); ?>.</span> <span class="mobile_group"><?php echo esc_html( $group ); // phpcs:ignore ?></span>
|
|
<input type="button" class="button mobile_delete"
|
|
value="<?php esc_html_e( 'Delete group', 'w3-total-cache' ); ?>"
|
|
<?php disabled( $useragent_groups['disabled'] ); ?> />
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="mobile_groups_<?php echo esc_attr( $group ); ?>_enabled"><?php esc_html_e( 'Enabled:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<input type="hidden" name="mobile_groups[<?php echo esc_attr( $group ); ?>][enabled]" value="0" />
|
|
<input id="mobile_groups_<?php echo esc_attr( $group ); ?>_enabled"
|
|
class="mobile_group_enabled" type="checkbox"
|
|
name="mobile_groups[<?php echo esc_attr( $group ); ?>][enabled]"
|
|
<?php disabled( $useragent_groups['disabled'] ); ?> value="1"
|
|
<?php checked( $group_config['enabled'], true ); ?> />
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="mobile_groups_<?php echo esc_attr( $group ); ?>_theme"><?php esc_html_e( 'Theme:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<select id="mobile_groups_<?php echo esc_attr( $group ); ?>_theme"
|
|
name="mobile_groups[<?php echo esc_attr( $group ); ?>][theme]"
|
|
<?php disabled( $useragent_groups['disabled'] ); ?> >
|
|
<option value=""><?php esc_html_e( '-- Pass-through --', 'w3-total-cache' ); ?></option>
|
|
<?php foreach ( $useragent_themes as $theme_key => $theme_name ) : ?>
|
|
<option value="<?php echo esc_attr( $theme_key ); ?>"<?php selected( $theme_key, $group_config['theme'] ); ?>><?php echo esc_html( $theme_name ); ?></option>
|
|
<?php endforeach; ?>
|
|
</select>
|
|
<p class="description">
|
|
<?php esc_html_e( 'Assign this group of user agents to a specific theme. Selecting "Pass-through" allows any plugin(s) (e.g. mobile plugins) to properly handle requests for these user agents. If the "redirect users to" field is not empty, this setting is ignored.', 'w3-total-cache' ); ?>
|
|
</p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="mobile_groups_<?php echo esc_attr( $group ); ?>_redirect"><?php esc_html_e( 'Redirect users to:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<input id="mobile_groups_<?php echo esc_attr( $group ); ?>_redirect"
|
|
type="text" name="mobile_groups[<?php echo esc_attr( $group ); ?>][redirect]"
|
|
value="<?php echo esc_attr( $group_config['redirect'] ); ?>"
|
|
<?php disabled( $useragent_groups['disabled'] ); ?>
|
|
size="60" />
|
|
<p class="description"><?php esc_html_e( 'A 302 redirect is used to send this group of users to another hostname (domain); recommended if a 3rd party service provides a mobile version of your site.', 'w3-total-cache' ); ?></p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="mobile_groups_<?php echo esc_attr( $group ); ?>_agents"><?php esc_html_e( 'User agents:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<textarea id="mobile_groups_<?php echo esc_attr( $group ); ?>_agents"
|
|
name="mobile_groups[<?php echo esc_attr( $group ); ?>][agents]"
|
|
rows="10" cols="50" <?php disabled( $useragent_groups['disabled'] ); ?>><?php echo esc_textarea( implode( "\r\n", (array) $group_config['agents'] ) ); ?></textarea>
|
|
<p class="description">
|
|
<?php esc_html_e( 'Specify the user agents for this group. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported.', 'w3-total-cache' ); ?>
|
|
</p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</li>
|
|
<?php endforeach; ?>
|
|
</ul>
|
|
<div id="mobile_groups_empty" style="display: none;"><?php esc_html_e( 'No groups added. All user agents recieve the same page and minify cache results.', 'w3-total-cache' ); ?></div>
|
|
|
|
<?php
|
|
Util_Ui::postbox_footer();
|
|
|
|
Util_Ui::postbox_header(
|
|
__( 'Note(s):', 'w3-total-cache' ),
|
|
'',
|
|
'notes'
|
|
);
|
|
?>
|
|
|
|
<table class="form-table">
|
|
<tr>
|
|
<th colspan="2">
|
|
<ul>
|
|
<?php echo $useragent_groups['description']; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
|
</ul>
|
|
</th>
|
|
</tr>
|
|
</table>
|
|
<?php Util_Ui::postbox_footer(); ?>
|
|
</div>
|
|
|
|
<!-- Referrer Groups -->
|
|
|
|
<script type="text/javascript">/*<![CDATA[*/
|
|
var referrer_themes = {};
|
|
<?php foreach ( $referrer_themes as $theme_key => $theme_name ) : ?>
|
|
referrer_themes['<?php echo esc_attr( $theme_key ); ?>'] = '<?php echo esc_html( $theme_name ); ?>';
|
|
<?php endforeach; ?>
|
|
/*]]>*/</script>
|
|
|
|
<div class="metabox-holder">
|
|
<?php Util_Ui::postbox_header( esc_html__( 'Manage Referrer Groups', 'w3-total-cache' ), '', 'manage-rg' ); ?>
|
|
<p>
|
|
<input id="referrer_add" type="button" class="button" value="<?php esc_html_e( 'Create a group', 'w3-total-cache' ); ?>" /> <?php esc_html_e( 'of referrers by specifying names in the referrers field. Assign a set of referrers to use a specific theme, redirect them to another domain, create referrer groups to ensure that a unique cache is created for each referrer group. Drag and drop groups into order (if needed) to determine their priority (top -> down).', 'w3-total-cache' ); ?>
|
|
</p>
|
|
|
|
<ul id="referrer_groups">
|
|
<?php
|
|
$index = 0;
|
|
|
|
foreach ( $referrer_groups as $group => $group_config ) :
|
|
$index++;
|
|
?>
|
|
<li id="referrer_group_<?php echo esc_attr( $group ); ?>">
|
|
<table class="form-table">
|
|
<tr>
|
|
<th>
|
|
<?php esc_html_e( 'Group name:', 'w3-total-cache' ); ?>
|
|
</th>
|
|
<td>
|
|
<span class="referrer_group_number"><?php echo esc_attr( $index ); ?>.</span> <span class="referrer_group"><?php echo esc_html( $group ); ?></span> <input type="button" class="button referrer_delete" value="<?php esc_html_e( 'Delete group', 'w3-total-cache' ); ?>" />
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="referrer_groups_<?php echo esc_attr( $group ); ?>_enabled"><?php esc_html_e( 'Enabled:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<input type="hidden" name="referrer_groups[<?php echo esc_attr( $group ); ?>][enabled]" value="0" />
|
|
<input id="referrer_groups_<?php echo esc_attr( $group ); ?>_enabled"
|
|
class="referrer_group_enabled" type="checkbox"
|
|
name="referrer_groups[<?php echo esc_attr( $group ); ?>][enabled]"
|
|
value="1"<?php checked( $group_config['enabled'], true ); ?> />
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="referrer_groups_<?php echo esc_attr( $group ); ?>_theme"><?php esc_html_e( 'Theme:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<select id="referrer_groups_<?php echo esc_attr( $group ); ?>_theme" name="referrer_groups[<?php echo esc_attr( $group ); ?>][theme]">
|
|
<option value=""><?php esc_html_e( '-- Pass-through --', 'w3-total-cache' ); ?></option>
|
|
<?php foreach ( $referrer_themes as $theme_key => $theme_name ) : ?>
|
|
<option value="<?php echo esc_attr( $theme_key ); ?>"<?php selected( $theme_key, $group_config['theme'] ); ?>><?php echo esc_html( $theme_name ); ?></option>
|
|
<?php endforeach; ?>
|
|
</select>
|
|
<p class="description"><?php esc_html_e( 'Assign this group of referrers to a specific theme. Selecting "Pass-through" allows any plugin(s) (e.g. referrer plugins) to properly handle requests for these referrers. If the "redirect users to" field is not empty, this setting is ignored.', 'w3-total-cache' ); ?></p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="referrer_groups_<?php echo esc_attr( $group ); ?>_redirect"><?php esc_html_e( 'Redirect users to:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<input id="referrer_groups_<?php echo esc_attr( $group ); ?>_redirect" type="text" name="referrer_groups[<?php echo esc_attr( $group ); ?>][redirect]" value="<?php echo esc_attr( $group_config['redirect'] ); ?>" size="60" />
|
|
<p class="description"><?php esc_html_e( 'A 302 redirect is used to send this group of referrers to another hostname (domain).', 'w3-total-cache' ); ?></p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="referrer_groups_<?php echo esc_attr( $group ); ?>_referrers"><?php esc_html_e( 'Referrers:', 'w3-total-cache' ); ?></label>
|
|
</th>
|
|
<td>
|
|
<textarea id="referrer_groups_<?php echo esc_attr( $group ); ?>_referrers" name="referrer_groups[<?php echo esc_attr( $group ); ?>][referrers]" rows="10" cols="50"><?php echo esc_textarea( implode( "\r\n", (array) $group_config['referrers'] ) ); ?></textarea>
|
|
<p class="description"><?php esc_html_e( 'Specify the referrers for this group. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported.', 'w3-total-cache' ); ?></p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</li>
|
|
<?php endforeach; ?>
|
|
</ul>
|
|
<div id="referrer_groups_empty" style="display: none;"><?php esc_html_e( 'No groups added. All referrers recieve the same page and minify cache results.', 'w3-total-cache' ); ?></div>
|
|
|
|
<?php Util_Ui::postbox_footer(); ?>
|
|
</div>
|
|
|
|
<!-- Cookie Groups -->
|
|
|
|
<div class="metabox-holder">
|
|
<?php Util_Ui::postbox_header( esc_html__( 'Manage Cookie Groups', 'w3-total-cache' ), '', 'manage-cg' ); ?>
|
|
<p>
|
|
<input id="w3tc_cookiegroup_add" type="button" class="button"
|
|
<?php disabled( $cookie_groups['disabled'] ); ?>
|
|
value="<?php esc_html_e( 'Create a group', 'w3-total-cache' ); ?>" />
|
|
<?php esc_html_e( 'of Cookies by specifying names in the Cookies field. Assign a set of Cookies to ensure that a unique cache is created for each Cookie group. Drag and drop groups into order (if needed) to determine their priority (top -> down).', 'w3-total-cache' ); ?>
|
|
</p>
|
|
|
|
<ul id="cookiegroups" class="w3tc_cachegroups">
|
|
<?php
|
|
$index = 0;
|
|
foreach ( $cookie_groups['value'] as $group => $group_config ) :
|
|
$index++;
|
|
?>
|
|
<li id="cookiegroup_<?php echo esc_attr( $group ); ?>">
|
|
<table class="form-table">
|
|
<tr>
|
|
<th>
|
|
<?php esc_html_e( 'Group name:', 'w3-total-cache' ); ?>
|
|
</th>
|
|
<td>
|
|
<span class="cookiegroup_number"><?php echo esc_attr( $index ); ?>.</span>
|
|
<span class="cookiegroup_name"><?php echo htmlspecialchars( $group ); // phpcs:ignore ?></span>
|
|
<input type="button" class="button w3tc_cookiegroup_delete"
|
|
value="<?php esc_html_e( 'Delete group', 'w3-total-cache' ); ?>"
|
|
<?php disabled( $cookie_groups['disabled'] ); ?> />
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="cookiegroup_<?php echo esc_attr( $group ); ?>_enabled">
|
|
<?php esc_html_e( 'Enabled:', 'w3-total-cache' ); ?>
|
|
</label>
|
|
</th>
|
|
<td>
|
|
<input id="cookiegroup_<?php echo esc_attr( $group ); ?>_enabled"
|
|
class="cookiegroup_enabled" type="checkbox"
|
|
name="cookiegroups[<?php echo esc_attr( $group ); ?>][enabled]"
|
|
<?php disabled( $cookie_groups['disabled'] ); ?> value="1"
|
|
<?php checked( $group_config['enabled'], true ); ?> />
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="cookiegroup_<?php echo esc_attr( $group ); ?>_cache">
|
|
<?php esc_html_e( 'Cache:', 'w3-total-cache' ); ?>
|
|
</label>
|
|
</th>
|
|
<td>
|
|
<input id="cookiegroup_<?php echo esc_attr( $group ); ?>_cache"
|
|
type="checkbox"
|
|
name="cookiegroups[<?php echo esc_attr( $group ); ?>][cache]"
|
|
<?php disabled( $cookie_groups['disabled'] ); ?> value="1"
|
|
<?php checked( $group_config['cache'], true ); ?> /> <?php esc_html_e( 'Enable', 'w3-total-cache' ); ?>
|
|
<p class="description"><?php esc_html_e( 'Controls whether web pages can be cached or not when cookies from this group are detected.', 'w3-total-cache' ); ?></p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
<label for="cookiegroup_<?php echo esc_attr( $group ); ?>_cookies">
|
|
<?php esc_html_e( 'Cookies:', 'w3-total-cache' ); ?>
|
|
</label>
|
|
</th>
|
|
<td>
|
|
<textarea id="cookiegroup_<?php echo esc_attr( $group ); ?>_cookies"
|
|
name="cookiegroups[<?php echo esc_attr( $group ); ?>][cookies]"
|
|
rows="10" cols="50" <?php disabled( $cookie_groups['disabled'] ); ?>><?php echo esc_textarea( implode( "\r\n", (array) $group_config['cookies'] ) ); ?></textarea>
|
|
<p class="description">
|
|
<?php esc_html_e( 'Specify the cookies for this group. Values like \'cookie\', \'cookie=value\', and cookie[a-z]+=value[a-z]+ are supported. Remember to escape special characters like spaces, dots or dashes with a backslash. Regular expressions are also supported.', 'w3-total-cache' ); ?>
|
|
</p>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</li>
|
|
<?php endforeach; ?>
|
|
</ul>
|
|
<div id="cookiegroups_empty" style="display: none;"><?php esc_html_e( 'No groups added. All Cookies recieve the same page and minify cache results.', 'w3-total-cache' ); ?></div>
|
|
|
|
<?php
|
|
Util_Ui::postbox_footer();
|
|
|
|
Util_Ui::postbox_header(
|
|
__( 'Note(s):', 'w3-total-cache' ),
|
|
'',
|
|
'notes'
|
|
);
|
|
?>
|
|
<table class="form-table">
|
|
<tr>
|
|
<th colspan="2">
|
|
<ul>
|
|
<li>
|
|
<?php esc_html_e( 'Content is cached for each group separately.', 'w3-total-cache' ); ?>
|
|
</li>
|
|
<li>
|
|
<?php esc_html_e( 'Per the above, make sure that visitors are notified about the cookie as per any regulations in your market.', 'w3-total-cache' ); ?>
|
|
</li>
|
|
</ul>
|
|
</th>
|
|
</tr>
|
|
</table>
|
|
<?php Util_Ui::postbox_footer(); ?>
|
|
</div>
|
|
|
|
</form>
|