Support Forum
Whenever I visit a page in Simple:Press Admin, I see in the Firebug "Net" panel that it's trying to call the following:
example.com/wp-content/plugins/simple-press/admin/resources/jscript/sp-admin-events.js?ver=b49226455124b19b22e633771dbb7f1f
Resulting in a 404 error. I have WP 4.6.1 and SimplePress Version: 5.7.1 Build: 14502. (I also still have "Enable combining and caching of forum script (JS) files" unchecked from when I was doing development work.)
I found that in the following file:
\wp-content\plugins\simple-press\sp-startup\admin\spa-admin-framework.php
It makes the following call:
$script = (defined('SP_SCRIPTS_DEBUG') && SP_SCRIPTS_DEBUG) ? SFAJSCRIPT.'spa-admin-events-dev.js' : SFAJSCRIPT.'sp-admin-events.js';
So here is where it's being called, clearly. But 1) the "sp-admin-events.js" file doesn't exist anywhere, and 2) I'm not aware of any debug mode.
Why is it calling a file that doesn't exist by default, and only calling the file that does exist ("spa-admin-events.js") when it's in some debug mode? Is this a bug? Thank you!
Oh wow. That's a clear and plain typo and I can't explain why we have not heard of this before now. Look at the code. The file is named 'spa-admin-events-dev.js' but that else clause calls is 'sp-' not 'spa-' as it should be.
That's bad.
As explanation - the main file is minimised and compressed and the debug version is not. You can define a constant of SFAJSCRIPT set to true to run the uncompressed versions of the files. Good for debugging and testing. WordPress allows for similar constants to be defined.
For now I would advise you to edit the name of the errant file - or edit the code where it is loaded. And we will clean up the bug quickly. We are planning a release fairly imminently as it happens.
And apologies for the typo.
YELLOW
SWORDFISH
|
1 Guest(s)