Skip to content

Commit 223fd1c

Browse files
committed
Don't escape phpVars
1 parent 439a91f commit 223fd1c

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

featherbb/Core/Interfaces/Lang.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public static function construct($domain = 'FeatherBB')
2020
public static function load($file, $domain = 'FeatherBB', $path = false, $language = false)
2121
{
2222
// Set default path to forum core translations
23-
$path = $path ? $path : ForumEnv::get('FEATHER_ROOT').'featherbb/lang';
23+
$path = $path ? $path : ForumEnv::get('FEATHER_ROOT').'featherbb/lang';
2424
// Set default language to current user
2525
if (!$language) {
2626
$language = (!User::get(null)) ? 'English' : User::getPref('language');

featherbb/View/layout.html.twig

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -321,16 +321,16 @@
321321
{% endif %}
322322
</section>
323323

324+
<!-- JSRAW -->
325+
<script>
326+
var baseUrl = '{{ urlBase() }}',
327+
phpVars = {{ jsVars|json_encode()|raw }};
328+
{{ jsraw|raw }}
329+
</script>
324330
<!-- JS -->
325331
{% for script in assets.js %}
326332
<script {% for key, value in script.params %}{{ key }}="{{ value }}"{% endfor %} src="{{ urlBase() }}/{{ script.file }}" /></script>
327333
{% endfor %}
328-
<!-- JSRAW -->
329-
<script>
330-
var baseUrl = '{{ urlBase() }}',
331-
phpVars = {{ jsVars|json_encode() }};
332-
{{ jsraw|raw }}
333-
</script>
334334
{{ fireHook('view.footer.before.html.tag') }}
335335
</body>
336336
</html>

0 commit comments

Comments
 (0)