Version Description
- WPML compatibility when use different domains for each language
- Replaced google social as it produced some JavaScript errors.
- Do not apply the admin/login replacements if permalinks where not applied.
- Language Po file update
- Minify replaces 'Remove new line carriage'
- Minify Html, Css, JavaScript
- Options for Minify to compress different components
- Fixed conflict with Shield Security
Download this release
Release Info
Developer | nsp-code |
Plugin | WP Hide & Security Enhancer |
Version | 1.4.8.2 |
Comparing to | |
See all releases |
Code changes from version 1.4.7.6 to 1.4.8.2
- conflicts/wp-simple-firewall.php +3 -2
- conflicts/wpml.php +82 -0
- css/wph.css +2 -6
- include/functions.class.php +0 -8
- include/update.class.php +11 -0
- include/wph.class.php +8 -0
- languages/wp-hide-security-enhancer.mo +0 -0
- languages/wp-hide-security-enhancer.po +60 -47
- modules/components/general-html.php +104 -6
- readme.txt +26 -4
- router/environment.php +1 -1
- wp-hide.php +1 -1
conflicts/wp-simple-firewall.php
CHANGED
@@ -21,7 +21,7 @@
|
|
21 |
if( ! self::is_plugin_active())
|
22 |
return FALSE;
|
23 |
|
24 |
-
add_action('plugins_loaded', array( 'WPH_conflict_handle_wp_simple_firewall', 'on_plugins_loaded' ),
|
25 |
|
26 |
}
|
27 |
|
@@ -29,7 +29,8 @@
|
|
29 |
static public function on_plugins_loaded()
|
30 |
{
|
31 |
|
32 |
-
|
|
|
33 |
|
34 |
//check if custom login is active
|
35 |
if( ! $oICWP_Wpsf_Controller->oFeatureHandlerLoginProtect->getIsCustomLoginPathEnabled())
|
21 |
if( ! self::is_plugin_active())
|
22 |
return FALSE;
|
23 |
|
24 |
+
add_action('plugins_loaded', array( 'WPH_conflict_handle_wp_simple_firewall', 'on_plugins_loaded' ), 5);
|
25 |
|
26 |
}
|
27 |
|
29 |
static public function on_plugins_loaded()
|
30 |
{
|
31 |
|
32 |
+
$oICWP_Wpsf_Controller = ICWP_WPSF_Plugin_Controller::GetInstance( WP_PLUGIN_DIR . '/wp-simple-firewall/icwp-wpsf.php' );
|
33 |
+
//$oICWP_Wpsf = ICWP_WPSF_Shield_Security::GetInstance( $oICWP_Wpsf_Controller );
|
34 |
|
35 |
//check if custom login is active
|
36 |
if( ! $oICWP_Wpsf_Controller->oFeatureHandlerLoginProtect->getIsCustomLoginPathEnabled())
|
conflicts/wpml.php
ADDED
@@ -0,0 +1,82 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
|
4 |
+
class WPH_conflict_handle_wpml
|
5 |
+
{
|
6 |
+
|
7 |
+
static function init()
|
8 |
+
{
|
9 |
+
add_action('plugins_loaded', array('WPH_conflict_handle_wpml', 'run') , -1);
|
10 |
+
}
|
11 |
+
|
12 |
+
static function is_plugin_active()
|
13 |
+
{
|
14 |
+
|
15 |
+
include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
|
16 |
+
|
17 |
+
if(is_plugin_active( 'sitepress-multilingual-cms/sitepress.php' ))
|
18 |
+
return TRUE;
|
19 |
+
else
|
20 |
+
return FALSE;
|
21 |
+
}
|
22 |
+
|
23 |
+
static public function run()
|
24 |
+
{
|
25 |
+
if( ! self::is_plugin_active())
|
26 |
+
return FALSE;
|
27 |
+
|
28 |
+
global $wph;
|
29 |
+
|
30 |
+
add_action('wp-hide/ob_start_callback', array('WPH_conflict_handle_wpml', 'wpml_domain_per_language'), 999);
|
31 |
+
|
32 |
+
}
|
33 |
+
|
34 |
+
/**
|
35 |
+
* Fix the replacement domain when using different domains for each WPML language
|
36 |
+
*
|
37 |
+
* @param mixed $buffer
|
38 |
+
*/
|
39 |
+
static public function wpml_domain_per_language( $buffer)
|
40 |
+
{
|
41 |
+
|
42 |
+
global $sitepress, $wph;
|
43 |
+
|
44 |
+
if (!$sitepress)
|
45 |
+
{
|
46 |
+
return $buffer;
|
47 |
+
}
|
48 |
+
|
49 |
+
$current_lang = apply_filters( 'wpml_current_language', NULL );
|
50 |
+
$default_lang = apply_filters('wpml_default_language', NULL );
|
51 |
+
$domain_per_lang = $sitepress->get_setting( 'language_negotiation_type' ) == WPML_LANGUAGE_NEGOTIATION_TYPE_DOMAIN ? true : false;
|
52 |
+
if ($current_lang == $default_lang || !$domain_per_lang)
|
53 |
+
{
|
54 |
+
return $buffer;
|
55 |
+
}
|
56 |
+
|
57 |
+
$replacement_list = $wph->functions->get_replacement_list();
|
58 |
+
$home_url = home_url();
|
59 |
+
$default_home_url = $sitepress->convert_url( $sitepress->get_wp_api()->get_home_url(), $default_lang );
|
60 |
+
$new_replacement_list = array();
|
61 |
+
|
62 |
+
if (!empty($replacement_list) && is_array($replacement_list))
|
63 |
+
{
|
64 |
+
foreach ($replacement_list as $old_url => $new_url)
|
65 |
+
{
|
66 |
+
$old_url = str_ireplace($default_home_url, $home_url, $old_url);
|
67 |
+
$new_url = str_ireplace($default_home_url, $home_url, $new_url);
|
68 |
+
$new_replacement_list[$old_url] = $new_url;
|
69 |
+
}
|
70 |
+
|
71 |
+
return $wph->functions->content_urls_replacement($buffer, $new_replacement_list );
|
72 |
+
}
|
73 |
+
|
74 |
+
return $buffer;
|
75 |
+
}
|
76 |
+
|
77 |
+
|
78 |
+
}
|
79 |
+
|
80 |
+
|
81 |
+
|
82 |
+
?>
|
css/wph.css
CHANGED
@@ -55,12 +55,8 @@ table.wph_input input[type=text]:focus,table.wph_input textarea:focus,table.wph_
|
|
55 |
|
56 |
#info_box {padding: 0 10px; border: 1px dashed #6aadcc; background-color: #FFF; margin: 10px 0 20px 0;-webkit-box-shadow: 1px 1px 7px rgba(50, 50, 50, 0.17);-moz-box-shadow: 1px 1px 7px rgba(50, 50, 50, 0.17);box-shadow: 1px 1px 7px rgba(50, 50, 50, 0.17);}
|
57 |
#info_box a {text-decoration: none}
|
58 |
-
#info_box #p_right {float: right;
|
59 |
-
#info_box
|
60 |
-
#info_box .p_s_item {float: none; padding: 0px 5px; margin: 0px; display: inline-block; vertical-align: middle;}
|
61 |
-
#info_box .p_s_item > iframe, #info_box .p_s_item > div {display: block}
|
62 |
-
#info_box .p_s_item.s_gp {padding-top: 3px; margin-left: 0px}
|
63 |
-
|
64 |
|
65 |
h2.subtitle {font-size: 15px; font-style: italic; font-weight: bold}
|
66 |
.wrap .example { color: #666666; font-size: 11px; font-weight: bold}
|
55 |
|
56 |
#info_box {padding: 0 10px; border: 1px dashed #6aadcc; background-color: #FFF; margin: 10px 0 20px 0;-webkit-box-shadow: 1px 1px 7px rgba(50, 50, 50, 0.17);-moz-box-shadow: 1px 1px 7px rgba(50, 50, 50, 0.17);box-shadow: 1px 1px 7px rgba(50, 50, 50, 0.17);}
|
57 |
#info_box a {text-decoration: none}
|
58 |
+
#info_box #p_right {float: right; background-color:#f5f5f5; border: 1px dashed #6aadcc; padding: 0px 10px; margin-top: 10px}
|
59 |
+
#info_box .p_s_item {float: right; padding: 0px 5px; margin-top: 10px; margin-bottom: 5px; }
|
|
|
|
|
|
|
|
|
60 |
|
61 |
h2.subtitle {font-size: 15px; font-style: italic; font-weight: bold}
|
62 |
.wrap .example { color: #666666; font-size: 11px; font-weight: bold}
|
include/functions.class.php
CHANGED
@@ -2435,14 +2435,6 @@
|
|
2435 |
<a href="https://twitter.com/share" class="twitter-share-button" data-url="http://www.wp-hide.com" data-text="Hide and increase Security for your WordPress website instance using smart techniques. No files are being changed." data-count="none">Tweet</a><script type="text/javascript" src="//platform.twitter.com/widgets.js"></script>
|
2436 |
</div>
|
2437 |
|
2438 |
-
<div class="p_s_item s_gp">
|
2439 |
-
<!-- Place this tag in your head or just before your close body tag -->
|
2440 |
-
<script type="text/javascript" src="https://apis.google.com/js/plusone.js"></script>
|
2441 |
-
|
2442 |
-
<!-- Place this tag where you want the +1 button to render -->
|
2443 |
-
<div class="g-plusone" data-size="small" data-annotation="none" data-href="http://nsp-code.com/"></div>
|
2444 |
-
</div>
|
2445 |
-
|
2446 |
<div class="clear"></div>
|
2447 |
</div>
|
2448 |
|
2435 |
<a href="https://twitter.com/share" class="twitter-share-button" data-url="http://www.wp-hide.com" data-text="Hide and increase Security for your WordPress website instance using smart techniques. No files are being changed." data-count="none">Tweet</a><script type="text/javascript" src="//platform.twitter.com/widgets.js"></script>
|
2436 |
</div>
|
2437 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2438 |
<div class="clear"></div>
|
2439 |
</div>
|
2440 |
|
include/update.class.php
CHANGED
@@ -194,6 +194,17 @@
|
|
194 |
$_trigger_flush_rules = TRUE;
|
195 |
|
196 |
$version = '1.4.7';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
197 |
}
|
198 |
|
199 |
|
194 |
$_trigger_flush_rules = TRUE;
|
195 |
|
196 |
$version = '1.4.7';
|
197 |
+
}
|
198 |
+
|
199 |
+
|
200 |
+
if(version_compare($version, '1.4.7.8', '<'))
|
201 |
+
{
|
202 |
+
if(isset($this->wph->settings['module_settings']['remove_html_new_lines']) && $this->wph->settings['module_settings']['remove_html_new_lines'] == "yes")
|
203 |
+
{
|
204 |
+
$this->wph->settings['module_settings']['remove_html_new_lines'] = 'all';
|
205 |
+
}
|
206 |
+
|
207 |
+
$version = '1.4.7.8';
|
208 |
}
|
209 |
|
210 |
|
include/wph.class.php
CHANGED
@@ -616,6 +616,10 @@
|
|
616 |
if($this->uninstall === TRUE)
|
617 |
return $location;
|
618 |
|
|
|
|
|
|
|
|
|
619 |
//do not replace 404 pages
|
620 |
global $wp_the_query;
|
621 |
|
@@ -1290,6 +1294,10 @@
|
|
1290 |
include_once(WPH_PATH . 'conflicts/woocommerce.php');
|
1291 |
WPH_conflict_handle_woocommerce::init();
|
1292 |
|
|
|
|
|
|
|
|
|
1293 |
}
|
1294 |
|
1295 |
|
616 |
if($this->uninstall === TRUE)
|
617 |
return $location;
|
618 |
|
619 |
+
//ignore if permalinks are available
|
620 |
+
if($this->permalinks_not_applied === TRUE)
|
621 |
+
return $location;
|
622 |
+
|
623 |
//do not replace 404 pages
|
624 |
global $wp_the_query;
|
625 |
|
1294 |
include_once(WPH_PATH . 'conflicts/woocommerce.php');
|
1295 |
WPH_conflict_handle_woocommerce::init();
|
1296 |
|
1297 |
+
//WPML
|
1298 |
+
include_once(WPH_PATH . 'conflicts/wpml.php');
|
1299 |
+
WPH_conflict_handle_wpml::init();
|
1300 |
+
|
1301 |
}
|
1302 |
|
1303 |
|
languages/wp-hide-security-enhancer.mo
CHANGED
Binary file
|
languages/wp-hide-security-enhancer.po
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
msgid ""
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: Post Types Order\n"
|
4 |
-
"POT-Creation-Date:
|
5 |
-
"PO-Revision-Date:
|
6 |
"Last-Translator: NspCode <contact@nsp-code.com>\n"
|
7 |
"Language-Team: \n"
|
8 |
"MIME-Version: 1.0\n"
|
@@ -13,7 +13,7 @@ msgstr ""
|
|
13 |
"X-Poedit-Basepath: ../\n"
|
14 |
"X-Poedit-SearchPath-0: .\n"
|
15 |
|
16 |
-
#: conflicts/wp-simple-firewall.php:
|
17 |
msgid ""
|
18 |
"<b>Conflict notice</b>: The Security Firewall - Login Protection use the "
|
19 |
"Rename WP Login Page functionality which is the same as WP Hide - Admin "
|
@@ -50,23 +50,23 @@ msgid ""
|
|
50 |
"changes to apply"
|
51 |
msgstr ""
|
52 |
|
53 |
-
#: include/functions.class.php:
|
54 |
#, php-format
|
55 |
msgid "The %1$s plugin header is deprecated. Use %2$s instead."
|
56 |
msgstr ""
|
57 |
|
58 |
-
#: include/functions.class.php:
|
59 |
#, php-format
|
60 |
msgid "By %s."
|
61 |
msgstr ""
|
62 |
|
63 |
-
#: include/functions.class.php:
|
64 |
msgid ""
|
65 |
"Help us to improve this plugin by sending any improvement suggestions and "
|
66 |
"reporting any issues at "
|
67 |
msgstr ""
|
68 |
|
69 |
-
#: include/functions.class.php:
|
70 |
msgid ""
|
71 |
"Did you find this plugin useful? Please support our work by spread the word "
|
72 |
"about this, or write an article about the plugin in your blog with a link to "
|
@@ -124,15 +124,15 @@ msgstr ""
|
|
124 |
msgid "Cache cleared"
|
125 |
msgstr ""
|
126 |
|
127 |
-
#: include/wph.class.php:
|
128 |
msgid "Unable to create environment static file. Is "
|
129 |
msgstr ""
|
130 |
|
131 |
-
#: include/wph.class.php:
|
132 |
msgid "writable"
|
133 |
msgstr ""
|
134 |
|
135 |
-
#: include/wph.class.php:
|
136 |
msgid "will not work correctly, so where turned off."
|
137 |
msgstr ""
|
138 |
|
@@ -204,13 +204,12 @@ msgstr ""
|
|
204 |
#: modules/components/general-feed.php:21
|
205 |
#: modules/components/general-headers.php:22
|
206 |
#: modules/components/general-headers.php:39
|
207 |
-
#: modules/components/general-html.php:
|
208 |
-
#: modules/components/general-html.php:
|
209 |
-
#: modules/components/general-html.php:
|
210 |
-
#: modules/components/general-html.php:
|
211 |
-
#: modules/components/general-html.php:
|
212 |
-
#: modules/components/general-html.php:
|
213 |
-
#: modules/components/general-html.php:113
|
214 |
#: modules/components/general-meta.php:22
|
215 |
#: modules/components/general-meta.php:38
|
216 |
#: modules/components/general-meta.php:54
|
@@ -261,13 +260,13 @@ msgstr ""
|
|
261 |
#: modules/components/general-feed.php:22
|
262 |
#: modules/components/general-headers.php:23
|
263 |
#: modules/components/general-headers.php:40
|
264 |
-
#: modules/components/general-html.php:
|
265 |
-
#: modules/components/general-html.php:
|
266 |
-
#: modules/components/general-html.php:
|
267 |
-
#: modules/components/general-html.php:
|
268 |
-
#: modules/components/general-html.php:
|
269 |
-
#: modules/components/general-html.php:
|
270 |
-
#: modules/components/general-html.php:
|
271 |
#: modules/components/general-meta.php:23
|
272 |
#: modules/components/general-meta.php:39
|
273 |
#: modules/components/general-meta.php:55
|
@@ -313,25 +312,25 @@ msgstr ""
|
|
313 |
msgid "No"
|
314 |
msgstr ""
|
315 |
|
316 |
-
#: modules/components/admin-admin_url.php:
|
317 |
msgid "Hello"
|
318 |
msgstr ""
|
319 |
|
320 |
-
#: modules/components/admin-admin_url.php:
|
321 |
msgid ""
|
322 |
"This is an automated message to inform that your login url has been changed "
|
323 |
"at"
|
324 |
msgstr ""
|
325 |
|
326 |
-
#: modules/components/admin-admin_url.php:
|
327 |
msgid "The new login url is"
|
328 |
msgstr ""
|
329 |
|
330 |
-
#: modules/components/admin-admin_url.php:
|
331 |
msgid "Additionality you can use this to recover the old login / admin links "
|
332 |
msgstr ""
|
333 |
|
334 |
-
#: modules/components/admin-admin_url.php:
|
335 |
msgid "Please keep this url safe for recover, if forgot"
|
336 |
msgstr ""
|
337 |
|
@@ -372,47 +371,61 @@ msgstr ""
|
|
372 |
msgid "Remove X-Pingback Header if being set."
|
373 |
msgstr ""
|
374 |
|
375 |
-
#: modules/components/general-html.php:
|
376 |
msgid ""
|
377 |
"Remove all HTML Comments which usualy specify Plugins Name and Version. Any "
|
378 |
"Internet Explorer conditional tags are preserved."
|
379 |
msgstr ""
|
380 |
|
381 |
-
#: modules/components/general-html.php:
|
382 |
-
msgid ""
|
383 |
-
|
384 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
385 |
msgstr ""
|
386 |
|
387 |
-
#: modules/components/general-html.php:
|
388 |
msgid "Remove general classes from body tag."
|
389 |
msgstr ""
|
390 |
|
391 |
-
#: modules/components/general-html.php:
|
392 |
-
#: modules/components/general-html.php:
|
393 |
-
#: modules/components/general-html.php:
|
394 |
-
#: modules/components/general-html.php:
|
395 |
-
#: modules/components/general-html.php:
|
396 |
msgid ""
|
397 |
"This can produce layout issues with certain themes, if something break this "
|
398 |
"should be turned off."
|
399 |
msgstr ""
|
400 |
|
401 |
-
#: modules/components/general-html.php:
|
402 |
msgid "Remove ID attribute from all menu items."
|
403 |
msgstr ""
|
404 |
|
405 |
-
#: modules/components/general-html.php:
|
406 |
msgid ""
|
407 |
"Remove class attribute from all menu items. Any classes which include a "
|
408 |
"\"current\" prefix or contain \"has-children\" will be preserved."
|
409 |
msgstr ""
|
410 |
|
411 |
-
#: modules/components/general-html.php:
|
412 |
msgid "Remove general classes from post."
|
413 |
msgstr ""
|
414 |
|
415 |
-
#: modules/components/general-html.php:
|
416 |
msgid "Remove general classes from media tags."
|
417 |
msgstr ""
|
418 |
|
@@ -677,7 +690,7 @@ msgstr ""
|
|
677 |
msgid "Child - Remove description header from Style file"
|
678 |
msgstr ""
|
679 |
|
680 |
-
#: modules/components/rewrite-new_theme_path.php:
|
681 |
msgid ""
|
682 |
"When changing the Child Theme Path it is recommended to also change the Main "
|
683 |
"Theme Path to avoid relative paths issues within style files and layout "
|
@@ -707,8 +720,8 @@ msgstr ""
|
|
707 |
#: modules/components/rewrite-new_upload_path.php:31
|
708 |
msgid ""
|
709 |
"If set to Yes, all new images inserted into posts will use the new Upload "
|
710 |
-
"Url, as old url become blocked. Using the No, new images
|
711 |
-
"old url, which however are being updated on front side. This may be
|
712 |
"on plugin disable, so image urls can be accessible as before."
|
713 |
msgstr ""
|
714 |
|
1 |
msgid ""
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: Post Types Order\n"
|
4 |
+
"POT-Creation-Date: 2018-01-25 23:17+0200\n"
|
5 |
+
"PO-Revision-Date: 2018-01-25 23:17+0200\n"
|
6 |
"Last-Translator: NspCode <contact@nsp-code.com>\n"
|
7 |
"Language-Team: \n"
|
8 |
"MIME-Version: 1.0\n"
|
13 |
"X-Poedit-Basepath: ../\n"
|
14 |
"X-Poedit-SearchPath-0: .\n"
|
15 |
|
16 |
+
#: conflicts/wp-simple-firewall.php:93
|
17 |
msgid ""
|
18 |
"<b>Conflict notice</b>: The Security Firewall - Login Protection use the "
|
19 |
"Rename WP Login Page functionality which is the same as WP Hide - Admin "
|
50 |
"changes to apply"
|
51 |
msgstr ""
|
52 |
|
53 |
+
#: include/functions.class.php:2080
|
54 |
#, php-format
|
55 |
msgid "The %1$s plugin header is deprecated. Use %2$s instead."
|
56 |
msgstr ""
|
57 |
|
58 |
+
#: include/functions.class.php:2165
|
59 |
#, php-format
|
60 |
msgid "By %s."
|
61 |
msgstr ""
|
62 |
|
63 |
+
#: include/functions.class.php:2450
|
64 |
msgid ""
|
65 |
"Help us to improve this plugin by sending any improvement suggestions and "
|
66 |
"reporting any issues at "
|
67 |
msgstr ""
|
68 |
|
69 |
+
#: include/functions.class.php:2451
|
70 |
msgid ""
|
71 |
"Did you find this plugin useful? Please support our work by spread the word "
|
72 |
"about this, or write an article about the plugin in your blog with a link to "
|
124 |
msgid "Cache cleared"
|
125 |
msgstr ""
|
126 |
|
127 |
+
#: include/wph.class.php:776
|
128 |
msgid "Unable to create environment static file. Is "
|
129 |
msgstr ""
|
130 |
|
131 |
+
#: include/wph.class.php:776
|
132 |
msgid "writable"
|
133 |
msgstr ""
|
134 |
|
135 |
+
#: include/wph.class.php:776
|
136 |
msgid "will not work correctly, so where turned off."
|
137 |
msgstr ""
|
138 |
|
204 |
#: modules/components/general-feed.php:21
|
205 |
#: modules/components/general-headers.php:22
|
206 |
#: modules/components/general-headers.php:39
|
207 |
+
#: modules/components/general-html.php:26
|
208 |
+
#: modules/components/general-html.php:60
|
209 |
+
#: modules/components/general-html.php:75
|
210 |
+
#: modules/components/general-html.php:91
|
211 |
+
#: modules/components/general-html.php:106
|
212 |
+
#: modules/components/general-html.php:121
|
|
|
213 |
#: modules/components/general-meta.php:22
|
214 |
#: modules/components/general-meta.php:38
|
215 |
#: modules/components/general-meta.php:54
|
260 |
#: modules/components/general-feed.php:22
|
261 |
#: modules/components/general-headers.php:23
|
262 |
#: modules/components/general-headers.php:40
|
263 |
+
#: modules/components/general-html.php:27
|
264 |
+
#: modules/components/general-html.php:42
|
265 |
+
#: modules/components/general-html.php:61
|
266 |
+
#: modules/components/general-html.php:76
|
267 |
+
#: modules/components/general-html.php:92
|
268 |
+
#: modules/components/general-html.php:107
|
269 |
+
#: modules/components/general-html.php:122
|
270 |
#: modules/components/general-meta.php:23
|
271 |
#: modules/components/general-meta.php:39
|
272 |
#: modules/components/general-meta.php:55
|
312 |
msgid "No"
|
313 |
msgstr ""
|
314 |
|
315 |
+
#: modules/components/admin-admin_url.php:184
|
316 |
msgid "Hello"
|
317 |
msgstr ""
|
318 |
|
319 |
+
#: modules/components/admin-admin_url.php:185
|
320 |
msgid ""
|
321 |
"This is an automated message to inform that your login url has been changed "
|
322 |
"at"
|
323 |
msgstr ""
|
324 |
|
325 |
+
#: modules/components/admin-admin_url.php:186
|
326 |
msgid "The new login url is"
|
327 |
msgstr ""
|
328 |
|
329 |
+
#: modules/components/admin-admin_url.php:187
|
330 |
msgid "Additionality you can use this to recover the old login / admin links "
|
331 |
msgstr ""
|
332 |
|
333 |
+
#: modules/components/admin-admin_url.php:188
|
334 |
msgid "Please keep this url safe for recover, if forgot"
|
335 |
msgstr ""
|
336 |
|
371 |
msgid "Remove X-Pingback Header if being set."
|
372 |
msgstr ""
|
373 |
|
374 |
+
#: modules/components/general-html.php:22
|
375 |
msgid ""
|
376 |
"Remove all HTML Comments which usualy specify Plugins Name and Version. Any "
|
377 |
"Internet Explorer conditional tags are preserved."
|
378 |
msgstr ""
|
379 |
|
380 |
+
#: modules/components/general-html.php:38
|
381 |
+
msgid "Minify HTML, Inline Styles, Inline JavaScripts."
|
382 |
+
msgstr ""
|
383 |
+
|
384 |
+
#: modules/components/general-html.php:43
|
385 |
+
msgid "Html"
|
386 |
+
msgstr ""
|
387 |
+
|
388 |
+
#: modules/components/general-html.php:44
|
389 |
+
msgid "Html & Css"
|
390 |
+
msgstr ""
|
391 |
+
|
392 |
+
#: modules/components/general-html.php:45
|
393 |
+
msgid "Html & JavaScript"
|
394 |
+
msgstr ""
|
395 |
+
|
396 |
+
#: modules/components/general-html.php:46
|
397 |
+
msgid "All"
|
398 |
msgstr ""
|
399 |
|
400 |
+
#: modules/components/general-html.php:57
|
401 |
msgid "Remove general classes from body tag."
|
402 |
msgstr ""
|
403 |
|
404 |
+
#: modules/components/general-html.php:57
|
405 |
+
#: modules/components/general-html.php:72
|
406 |
+
#: modules/components/general-html.php:87
|
407 |
+
#: modules/components/general-html.php:103
|
408 |
+
#: modules/components/general-html.php:118
|
409 |
msgid ""
|
410 |
"This can produce layout issues with certain themes, if something break this "
|
411 |
"should be turned off."
|
412 |
msgstr ""
|
413 |
|
414 |
+
#: modules/components/general-html.php:72
|
415 |
msgid "Remove ID attribute from all menu items."
|
416 |
msgstr ""
|
417 |
|
418 |
+
#: modules/components/general-html.php:87
|
419 |
msgid ""
|
420 |
"Remove class attribute from all menu items. Any classes which include a "
|
421 |
"\"current\" prefix or contain \"has-children\" will be preserved."
|
422 |
msgstr ""
|
423 |
|
424 |
+
#: modules/components/general-html.php:103
|
425 |
msgid "Remove general classes from post."
|
426 |
msgstr ""
|
427 |
|
428 |
+
#: modules/components/general-html.php:118
|
429 |
msgid "Remove general classes from media tags."
|
430 |
msgstr ""
|
431 |
|
690 |
msgid "Child - Remove description header from Style file"
|
691 |
msgstr ""
|
692 |
|
693 |
+
#: modules/components/rewrite-new_theme_path.php:753
|
694 |
msgid ""
|
695 |
"When changing the Child Theme Path it is recommended to also change the Main "
|
696 |
"Theme Path to avoid relative paths issues within style files and layout "
|
720 |
#: modules/components/rewrite-new_upload_path.php:31
|
721 |
msgid ""
|
722 |
"If set to Yes, all new images inserted into posts will use the new Upload "
|
723 |
+
"Url, as old url become blocked. Using the No, new images inserted will use "
|
724 |
+
"old url, which however are being updated on front side. This may be helpful "
|
725 |
"on plugin disable, so image urls can be accessible as before."
|
726 |
msgstr ""
|
727 |
|
modules/components/general-html.php
CHANGED
@@ -4,6 +4,11 @@
|
|
4 |
|
5 |
class WPH_module_general_html extends WPH_module_component
|
6 |
{
|
|
|
|
|
|
|
|
|
|
|
7 |
function get_component_title()
|
8 |
{
|
9 |
return "HTML";
|
@@ -29,13 +34,16 @@
|
|
29 |
|
30 |
$this->module_settings[] = array(
|
31 |
'id' => 'remove_html_new_lines',
|
32 |
-
'label' => '
|
33 |
-
'description' => __('
|
34 |
|
35 |
'input_type' => 'radio',
|
36 |
'options' => array(
|
37 |
-
'
|
38 |
-
'
|
|
|
|
|
|
|
39 |
),
|
40 |
'default_value' => 'no',
|
41 |
|
@@ -169,11 +177,101 @@
|
|
169 |
if(defined('WP_ADMIN'))
|
170 |
return $buffer;
|
171 |
|
172 |
-
$buffer
|
|
|
173 |
|
174 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
175 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
176 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
177 |
|
178 |
function _init_clean_body_classes( $saved_field_data )
|
179 |
{
|
4 |
|
5 |
class WPH_module_general_html extends WPH_module_component
|
6 |
{
|
7 |
+
|
8 |
+
public $buffer = '';
|
9 |
+
public $placeholders = array();
|
10 |
+
public $placeholder_hash = '';
|
11 |
+
|
12 |
function get_component_title()
|
13 |
{
|
14 |
return "HTML";
|
34 |
|
35 |
$this->module_settings[] = array(
|
36 |
'id' => 'remove_html_new_lines',
|
37 |
+
'label' => 'Minify',
|
38 |
+
'description' => __('Minify HTML, Inline Styles, Inline JavaScripts.', 'wp-hide-security-enhancer'),
|
39 |
|
40 |
'input_type' => 'radio',
|
41 |
'options' => array(
|
42 |
+
'no' => __('No', 'wp-hide-security-enhancer'),
|
43 |
+
'html' => __('Html', 'wp-hide-security-enhancer'),
|
44 |
+
'html_css' => __('Html & Css', 'wp-hide-security-enhancer'),
|
45 |
+
'html_js' => __('Html & JavaScript', 'wp-hide-security-enhancer'),
|
46 |
+
'all' => __('All', 'wp-hide-security-enhancer'),
|
47 |
),
|
48 |
'default_value' => 'no',
|
49 |
|
177 |
if(defined('WP_ADMIN'))
|
178 |
return $buffer;
|
179 |
|
180 |
+
$this->buffer = $buffer;
|
181 |
+
$this->placeholder_hash = '%WPH-PLACEHOLDER-REPLACEMENT';
|
182 |
|
183 |
+
switch ( $this->wph->settings['module_settings']['remove_html_new_lines'] )
|
184 |
+
{
|
185 |
+
case 'html' :
|
186 |
+
$this->add_css_placeholders ();
|
187 |
+
$this->add_js_placeholders ();
|
188 |
+
|
189 |
+
$this->buffer = preg_replace( "/\r|\n/", "", $this->buffer );
|
190 |
+
|
191 |
+
break;
|
192 |
+
|
193 |
+
case 'html_css' :
|
194 |
+
$this->add_js_placeholders ();
|
195 |
+
|
196 |
+
$this->buffer = preg_replace( "/\r|\n/", "", $this->buffer );
|
197 |
+
|
198 |
+
break;
|
199 |
+
|
200 |
+
case 'html_js' :
|
201 |
+
$this->add_css_placeholders ();
|
202 |
+
|
203 |
+
$this->buffer = preg_replace( "/\r|\n/", "", $this->buffer );
|
204 |
+
|
205 |
+
break;
|
206 |
+
|
207 |
+
case 'all' :
|
208 |
+
$this->buffer = preg_replace( "/\r|\n/", "", $this->buffer );
|
209 |
+
break;
|
210 |
+
|
211 |
+
}
|
212 |
+
|
213 |
+
//put back any placeholders
|
214 |
+
if( count($this->placeholders) > 0 )
|
215 |
+
{
|
216 |
+
foreach($this->placeholders as $placeholder => $data)
|
217 |
+
{
|
218 |
+
$this->buffer = str_replace($placeholder, $data, $this->buffer);
|
219 |
+
}
|
220 |
+
}
|
221 |
|
222 |
+
return $this->buffer;
|
223 |
+
|
224 |
+
}
|
225 |
+
|
226 |
+
|
227 |
+
|
228 |
+
function add_css_placeholders( )
|
229 |
+
{
|
230 |
+
$this->buffer = preg_replace_callback( '/(\\s*)<style(\\b[^>]*>)([\\s\\S]*?)<\\/style>(\\s*)/i', array($this, 'add_css_placeholders_callback') , $this->buffer);
|
231 |
}
|
232 |
+
|
233 |
+
function add_css_placeholders_callback( $match )
|
234 |
+
{
|
235 |
+
|
236 |
+
$pre_space = $match[1] === '' ? '' : ' ';
|
237 |
+
$tag_attrs = $match[2];
|
238 |
+
$tag_content = $match[3];
|
239 |
+
$post_space = $match[4] === '' ? '' : ' ';
|
240 |
+
|
241 |
+
$match_block = $pre_space . '<style' . $tag_attrs . $tag_content . '</style>' . $post_space;
|
242 |
+
|
243 |
+
$placeholder = $this->placeholder_hash . '-css-' . count( $this->placeholders ) . '%';
|
244 |
+
$this->placeholders[ $placeholder ] = $match_block;
|
245 |
+
|
246 |
+
return $placeholder;
|
247 |
+
|
248 |
+
}
|
249 |
+
|
250 |
+
|
251 |
+
function add_js_placeholders( )
|
252 |
+
{
|
253 |
+
|
254 |
+
$this->buffer = preg_replace_callback( '/(\\s*)<script(\\b[^>]*?>)([\\s\\S]*?)<\\/script>(\\s*)/i' ,array($this, 'add_js_placeholders_callback') , $this->buffer);
|
255 |
+
|
256 |
+
}
|
257 |
+
|
258 |
+
function add_js_placeholders_callback( $match )
|
259 |
+
{
|
260 |
+
|
261 |
+
$pre_space = $match[1] === '' ? '' : ' ';
|
262 |
+
$tag_attrs = $match[2];
|
263 |
+
$tag_content = $match[3];
|
264 |
+
$post_space = $match[4] === '' ? '' : ' ';
|
265 |
+
|
266 |
+
$match_block = $pre_space . '<script' . $tag_attrs . $tag_content . '</script>' . $post_space;
|
267 |
+
|
268 |
+
$placeholder = $this->placeholder_hash . '-js-' . count( $this->placeholders ) . '%';
|
269 |
+
$this->placeholders[ $placeholder ] = $match_block;
|
270 |
+
|
271 |
+
return $placeholder;
|
272 |
+
|
273 |
+
}
|
274 |
+
|
275 |
|
276 |
function _init_clean_body_classes( $saved_field_data )
|
277 |
{
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: nsp-code, tdgu
|
|
3 |
Donate link: https://www.nsp-code.com/
|
4 |
Tags: wordpress hide, hide, security, improve security, hacking, wp hide, custom login, wp-loging.php, wp-admin, admin hide, login change,
|
5 |
Requires at least: 2.8
|
6 |
-
Tested up to: 4.9.
|
7 |
-
Stable tag: 1.4.
|
8 |
License: GPLv2 or later
|
9 |
|
10 |
Hide and increase Security for your WordPress site instance using smart techniques. No files are changed on your server.
|
@@ -13,6 +13,9 @@ Hide and increase Security for your WordPress site instance using smart techniqu
|
|
13 |
|
14 |
The **easy way to completely hide your WordPress** core files, login page, theme and plugins paths from being show on front side. This is a huge improvement over Site Security, no one will know you actually run a WordPress. Provide a simple way to clean up html by removing all WordPress fingerprints.
|
15 |
|
|
|
|
|
|
|
16 |
Change the default WordPress login urls from wp-admin and wp-login.php to something totally arbitrary. No one will ever know where to try to guess a login and hack into your site. Totally invisible !!
|
17 |
|
18 |
[vimeo http://vimeo.com/185046480]
|
@@ -61,6 +64,7 @@ Once configured, you need to **clear server cache data and/or any cache plugins*
|
|
61 |
* Remove wlwmanifest Meta
|
62 |
* Remove rsd_link Meta
|
63 |
* Remove wpemoji
|
|
|
64 |
|
65 |
and many more.
|
66 |
|
@@ -137,7 +141,7 @@ Since version 1.2 Change individual plugin urls which make them unrecognizable,
|
|
137 |
|
138 |
**Rewrite > URL Slash**
|
139 |
|
140 |
-
* URL's add Slash - Add a slash to any links without. This disguise any existing
|
141 |
|
142 |
|
143 |
**General / Html > Meta**
|
@@ -189,7 +193,7 @@ Since version 1.2 Change individual plugin urls which make them unrecognizable,
|
|
189 |
**General / Html > HTML**
|
190 |
|
191 |
* Remove HTML Comments
|
192 |
-
*
|
193 |
* Remove general classes from body tag
|
194 |
* Remove ID from Menu items
|
195 |
* Remove class from Menu items
|
@@ -225,6 +229,14 @@ Since version 1.2 Change individual plugin urls which make them unrecognizable,
|
|
225 |
|
226 |
Feel free to contact us at electronice_delphi@yahoo.com
|
227 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
228 |
= Something is wrong, what can i do? =
|
229 |
|
230 |
* First, stay calm. There will be no harm, guaranteed :)
|
@@ -252,6 +264,16 @@ Please get in touch with us and we'll do our best to include it for a next versi
|
|
252 |
|
253 |
== Changelog ==
|
254 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
255 |
= 1.4.7.6 =
|
256 |
* PHP 7.2 compatibility
|
257 |
* Replaced trilingslashit from the end of template url to improve compatibility with urls (e.g. JavaScript variables) which does not include an ending slash.
|
3 |
Donate link: https://www.nsp-code.com/
|
4 |
Tags: wordpress hide, hide, security, improve security, hacking, wp hide, custom login, wp-loging.php, wp-admin, admin hide, login change,
|
5 |
Requires at least: 2.8
|
6 |
+
Tested up to: 4.9.4
|
7 |
+
Stable tag: 1.4.8.2
|
8 |
License: GPLv2 or later
|
9 |
|
10 |
Hide and increase Security for your WordPress site instance using smart techniques. No files are changed on your server.
|
13 |
|
14 |
The **easy way to completely hide your WordPress** core files, login page, theme and plugins paths from being show on front side. This is a huge improvement over Site Security, no one will know you actually run a WordPress. Provide a simple way to clean up html by removing all WordPress fingerprints.
|
15 |
|
16 |
+
**No file and directory change!**
|
17 |
+
No file and directory is being changed anywhere, everything is processed virtually! The plugin code use URL rewrite techniques and WordPress filters to apply all internal functionality and features. Everything is done automatically, there's no user intervention require at all.
|
18 |
+
|
19 |
Change the default WordPress login urls from wp-admin and wp-login.php to something totally arbitrary. No one will ever know where to try to guess a login and hack into your site. Totally invisible !!
|
20 |
|
21 |
[vimeo http://vimeo.com/185046480]
|
64 |
* Remove wlwmanifest Meta
|
65 |
* Remove rsd_link Meta
|
66 |
* Remove wpemoji
|
67 |
+
* Minify Html, Css, JavaScript
|
68 |
|
69 |
and many more.
|
70 |
|
141 |
|
142 |
**Rewrite > URL Slash**
|
143 |
|
144 |
+
* URL's add Slash - Add a slash to any links without. This disguise any existing for a file, folder or a wrong url, they all be all slashed.
|
145 |
|
146 |
|
147 |
**General / Html > Meta**
|
193 |
**General / Html > HTML**
|
194 |
|
195 |
* Remove HTML Comments
|
196 |
+
* Minify Html, Css, JavaScript
|
197 |
* Remove general classes from body tag
|
198 |
* Remove ID from Menu items
|
199 |
* Remove class from Menu items
|
229 |
|
230 |
Feel free to contact us at electronice_delphi@yahoo.com
|
231 |
|
232 |
+
= Does the plugin change anything on my server =
|
233 |
+
|
234 |
+
Absolute none! No file and directory is being changed anywhere, everything is processed virtually! The plugin code use URL rewrite techniques and WordPress filters to apply all internal functionality and features.
|
235 |
+
|
236 |
+
= Can i still update WordPress, my plugins and themes? =
|
237 |
+
|
238 |
+
Everything works as before, no functionality is being breaked. You can run updates at any time.
|
239 |
+
|
240 |
= Something is wrong, what can i do? =
|
241 |
|
242 |
* First, stay calm. There will be no harm, guaranteed :)
|
264 |
|
265 |
== Changelog ==
|
266 |
|
267 |
+
= 1.4.8.2 =
|
268 |
+
* WPML compatibility when use different domains for each language
|
269 |
+
* Replaced google social as it produced some JavaScript errors.
|
270 |
+
* Do not apply the admin/login replacements if permalinks where not applied.
|
271 |
+
* Language Po file update
|
272 |
+
* Minify replaces 'Remove new line carriage'
|
273 |
+
* Minify Html, Css, JavaScript
|
274 |
+
* Options for Minify to compress different components
|
275 |
+
* Fixed conflict with Shield Security
|
276 |
+
|
277 |
= 1.4.7.6 =
|
278 |
* PHP 7.2 compatibility
|
279 |
* Replaced trilingslashit from the end of template url to improve compatibility with urls (e.g. JavaScript variables) which does not include an ending slash.
|
router/environment.php
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
<?php if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
2 |
-
$environment_variable = '{"theme":{"folder_name":"
|
1 |
<?php if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
2 |
+
$environment_variable = '{"theme":{"folder_name":"twentyseventeen","mapped_name":""},"allowed_paths":["F:\/htdocs\/wp01\/wp-hide-wpml.test\/wp-content\/themes"],"cache_path":"F:\/htdocs\/wp01\/wp-content\/cache\/wph\/","wordpress_directory":"","site_relative_path":"\/"}' ?>
|
wp-hide.php
CHANGED
@@ -5,7 +5,7 @@ Plugin URI: https://www.wp-hide.com/
|
|
5 |
Description: Hide and increase Security for your WordPress website instance using smart techniques. No files are changed on your server.
|
6 |
Author: Nsp Code
|
7 |
Author URI: http://www.nsp-code.com
|
8 |
-
Version: 1.4.
|
9 |
Text Domain: wp-hide-security-enhancer
|
10 |
Domain Path: /languages/
|
11 |
*/
|
5 |
Description: Hide and increase Security for your WordPress website instance using smart techniques. No files are changed on your server.
|
6 |
Author: Nsp Code
|
7 |
Author URI: http://www.nsp-code.com
|
8 |
+
Version: 1.4.8.2
|
9 |
Text Domain: wp-hide-security-enhancer
|
10 |
Domain Path: /languages/
|
11 |
*/
|