| 1 |
<?php |
| 2 |
if (!defined('ABSPATH')) { |
| 3 |
exit; |
| 4 |
} |
| 5 |
?> |
| 6 |
<tr valign="top"> |
| 7 |
<th scope="row">X-Powered-By |
| 8 |
<p class="description"><?php esc_html_e('Specifies the technology (e.g. ASP.NET, PHP, JBoss, Express) supporting the web application, i.e. the scripting language. It is recommended to remove it or provide misleading information to throw off hackers that might target a particular technology/version.', 'http-headers'); ?></p> |
| 9 |
</th> |
| 10 |
<td> |
| 11 |
<fieldset> |
| 12 |
<legend class="screen-reader-text">X-Powered-By</legend> |
| 13 |
<?php |
| 14 |
$http_headers_x_powered_by = get_option ( 'hh_x_powered_by', 0 ); |
| 15 |
foreach ( $http_headers_bools as $http_headers_k => $http_headers_v ) { |
| 16 |
?><p> |
| 17 |
<label><input type="radio" class="http-header" name="hh_x_powered_by" value="<?php echo esc_attr($http_headers_k); ?>" <?php checked($http_headers_x_powered_by, $http_headers_k, true); ?> /> <?php echo esc_html($http_headers_v); ?></label> |
| 18 |
</p><?php |
| 19 |
} |
| 20 |
?> |
| 21 |
</fieldset> |
| 22 |
</td> |
| 23 |
<td> |
| 24 |
<?php settings_fields( 'http-headers-xpb' ); ?> |
| 25 |
<?php do_settings_sections( 'http-headers-xpb' ); ?> |
| 26 |
<select name="hh_x_powered_by_option" class="http-header-value"<?php echo $http_headers_x_powered_by == 1 ? NULL : ' readonly'; ?>> |
| 27 |
<?php |
| 28 |
$http_headers_items = array ( |
| 29 |
'unset' => 'Unset', |
| 30 |
'set' => 'Set', |
| 31 |
); |
| 32 |
$http_headers_x_powered_by_option = get_option ( 'hh_x_powered_by_option' ); |
| 33 |
foreach ( $http_headers_items as $http_headers_k => $http_headers_v ) { |
| 34 |
?><option value="<?php echo esc_attr($http_headers_k); ?>" <?php selected($http_headers_x_powered_by_option, $http_headers_k); ?>><?php echo esc_html($http_headers_v); ?></option><?php |
| 35 |
} |
| 36 |
?> |
| 37 |
</select> |
| 38 |
<input type="text" name="hh_x_powered_by_value" class="http-header-value" placeholder="PHP/<?php echo esc_attr(PHP_VERSION); ?>" value="<?php echo esc_attr(get_option('hh_x_powered_by_value')); ?>" |
| 39 |
<?php echo $http_headers_x_powered_by == 1 && $http_headers_x_powered_by_option == 'set' ? NULL : ' style="display: none" readonly'; ?> /> |
| 40 |
</td> |
| 41 |
</tr> |