Partial fix AdminCP does not respect $config['javaScriptUrl']

tyteen4a03

Well-known member
This is the public javascript bit:
Code:
<script src="{$jQuerySource}"></script>
<xen:if is="{$jQuerySource} != {$jQuerySourceLocal}">
<script>if (!window.jQuery) { document.write('<scr'+'ipt type="text/javascript" src="{$jQuerySourceLocal}"><\/scr'+'ipt>'); }</script>
</xen:if><xen:if is="{$xenOptions.uncompressedJs} == 1 OR {$xenOptions.uncompressedJs} == 3">
<script src="{$javaScriptSource}/jquery/jquery.xenforo.rollup.js?_v={$xenOptions.jsVersion}"></script></xen:if>
<script src="{xen:helper javaScriptUrl, '{$javaScriptSource}/xenforo/xenforo.js?_v={$xenOptions.jsVersion}'}"></script>
<!--XenForo_Require:JS-->
This is the AdminCP javascript bit:

Code:
<script src="{$jQuerySource}"></script><xen:if is="{$xenOptions.uncompressedJs} == 1 OR {$xenOptions.uncompressedJs} == 3">
<script src="js/jquery/jquery.xenforo.rollup.js?_v={$xenOptions.jsVersion}"></script></xen:if>
<script src="{xen:helper javaScriptUrl, 'js/xenforo/xenforo.js?_v={$xenOptions.jsVersion}'}"></script>
<script src="{xen:helper javaScriptUrl, 'js/xenforo/acp_quicksearch.js?_v={$xenOptions.jsVersion}'}"></script>
As you can see, AdminCP Javascripts URLs are not padded with the {$javaScriptSource} variable.
 
I just checked and you're right... it looks like sidebar.js adheres to the prefix, but the rest don't. I guess I never noticed since not many users in admin area (just me). :)
 
I would say that this is sort of intentional as it does prevent some mistakes (aggressive CDN caching, files not being uploaded externally correctly, etc). But the issue is if it's not consistent.
 
I would say that this is sort of intentional as it does prevent some mistakes (aggressive CDN caching, files not being uploaded externally correctly, etc). But the issue is if it's not consistent.
So I have to retain a copy of the js folder in the root folder along with the CDN one?
 
Top Bottom