Jeff-Lewis
Forum Replies Created
-
Ah, good to know about the Code Reference. Will you apply the same fix to ITSec?
- This reply was modified 7 years, 6 months ago by Jeff-Lewis.
We get it on Windows. Haven’t tried linux. I’m surprised about wp_mkdir_p(). Did you file a bug? Thanks for the replies.
I have seen the same issue. It’s related to hosting on Windows.
The code you posted is part of the problem, but also is how $itsec_globals are initialized on Windows.
Line 82 in class-itsec-core.php
‘plugin_dir’ => plugin_dir_path( $plugin_file ), //the path of the plugin directoryplugin_dir_path( $plugin_file ) will return something like this on Windows -> “C:\wwwroot\mysite\wp-content\plugins\better-wp-security/”
Notice difference in back and forward slashes.
So later in the get_module_path( $file ) function you posted, it’s trying to remove “C:\wwwroot\mysite\wp-content\plugins\better-wp-security/” from “C:\wwwroot\mysite\wp-content\plugins\better-wp-security\core” which never works because it doesn’t match.
Then we end up with the physical path in the script URL when it’s used here.
wp_enqueue_script( ‘itsec_file_change_warning_js’, $this->module_path . ‘js/admin-file-change-warning.js’, array( ‘jquery’ ), $itsec_globals[‘plugin_build’] );
Essentially exposing to the world the physical path of your files on the server’s disk. This is not helping security.
Forum: Requests and Feedback
In reply to: Single Page Application model?I haven’t watched it all so I don’t know how useful the presentation is. WordPress will collide with the best native web app architectures at some point…
Building Data Driven Single Page Web Applications with WordPressForum: Plugins
In reply to: [WP Editor] [Plugin: WP Editor] enable editing of LESS filesYes, at least make .less files editable as text.