kurtsson / jekyll-multiple-languages-plugin

I18n support for Jekyll and Octopress
MIT License
923 stars 201 forks source link

"exclude_from_localizations" is set and errors show up #145

Open UnicrystalCN opened 5 years ago

UnicrystalCN commented 5 years ago

If exclude_from_localizations: [ "js", "img" , "fonts" , "css" ] is included in my _config.yml, then when I visit the non-default language page, errors will show up like:

[2019-08-14 03:58:09] ERROR /en/img/logonav.png' not found. [2019-08-14 03:58:09] ERROR/en/css/font-awesome.min.css' not found. [2019-08-14 03:58:09] ERROR /en/js/bootstrap.min.js' not found. [2019-08-14 03:58:09] ERROR/en/js/typeahead.bundle.min.js' not found. [2019-08-14 03:58:09] ERROR /en/js/main.js' not found. [2019-08-14 03:58:10] ERROR/en/css/font-awesome.min.css' not found. [2019-08-14 03:58:10] ERROR /en/img/logonav.png' not found. [2019-08-14 03:58:10] ERROR/en/js/bootstrap.min.js' not found. [2019-08-14 03:58:10] ERROR /en/js/main.js' not found. [2019-08-14 03:58:10] ERROR/en/js/typeahead.bundle.min.js' not found.

How can I solve this?

shushugah commented 4 years ago

en/img/logonav.png' should not exist, instead it should be /img/logonav.png' because it is not attached to any language.

kennyhyun commented 4 years ago

https://github.com/kurtsson/jekyll-multiple-languages-plugin#41-_configyml

The link in the html should be referenced via baseurl_root