Fix baseurl used by search to load json data

This commit is contained in:
Matthew Taylor 2018-10-09 15:56:14 -04:00
parent c8e6161b21
commit ff092165d2

View file

@ -8,9 +8,9 @@
<script type="text/javascript" src="{{"js/auto-complete.js" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}"></script> <script type="text/javascript" src="{{"js/auto-complete.js" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}"></script>
<script type="text/javascript"> <script type="text/javascript">
{{ if .Site.IsMultiLingual }} {{ if .Site.IsMultiLingual }}
var baseurl = "{{.Site.LanguagePrefix | relURL }}"; var baseurl = "{{.Site.BaseURL}}{{.Site.LanguagePrefix}}";
{{ else }} {{ else }}
var baseurl = '{{ "" | relURL }}'; var baseurl = "{{.Site.BaseURL}}";
{{ end }} {{ end }}
</script> </script>
<script type="text/javascript" src="{{"js/search.js" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}"></script> <script type="text/javascript" src="{{"js/search.js" | relURL}}{{ if $assetBusting }}?{{ now.Unix }}{{ end }}"></script>