forked from BoldGrid/w3-total-cache
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCdn_Highwinds_Popup_View_SelectHost.php
60 lines (55 loc) · 1.58 KB
/
Cdn_Highwinds_Popup_View_SelectHost.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
<?php
namespace W3TC;
if ( ! defined( 'W3TC' ) ) {
die();
}
?>
<form action="admin.php?page=w3tc_cdn" method="post" style="padding: 20px"
class="w3tc_cdn_highwinds_form">
<?php
Util_Ui::hidden( '', 'account_hash', $details['account_hash'] );
Util_Ui::hidden( '', 'api_token', $details['api_token'] );
echo wp_kses(
Util_Ui::nonce_field( 'w3tc' ),
array(
'input' => array(
'type' => array(),
'name' => array(),
'value' => array(),
),
)
);
if ( isset( $details['error_message'] ) ) {
echo '<div class="error">' . esc_html( $details['error_message'] ) . '</div>';
}
?>
<div class="metabox-holder">
<?php Util_Ui::postbox_header( esc_html__( 'Select host to use', 'w3-total-cache' ) ); ?>
<table class="form-table">
<tr>
<td>Host:</td>
<td>
<?php foreach ( $details['hosts'] as $host ) : ?>
<label>
<input name="host" type="radio" class="w3tc-ignore-change"
value="<?php echo esc_attr( $host['hashCode'] ); ?>" />
<?php echo esc_html( $host['name'] ); ?>
(<?php echo esc_html( $host['hashCode'] ); ?>)
</label><br />
<?php endforeach; ?>
<label>
<input name="host" type="radio" class="w3tc-ignore-change" value="" />
Add new host:
</label>
<input name="host_new" type="text" class="w3tc-ignore-change" />
</td>
</tr>
</table>
<p class="submit">
<input type="button"
class="w3tc_cdn_highwinds_configure_host w3tc-button-save button-primary"
value="<?php esc_attr_e( 'Apply', 'w3-total-cache' ); ?>" />
</p>
<?php Util_Ui::postbox_footer(); ?>
</div>
</form>