Problem/Motivation
the module get the locale from the system (PT-BR) and try to get "https://cdn.datatables.net/plug-ins/1.10.20/i18n/Portuguese,%20Brazil.json" URL but the only URL that exist at DataTables is "https://cdn.datatables.net/plug-ins/1.10.20/i18n/Portuguese,%20Brasil.json", where "Brasil" is writed in the right way (for brazilians) but it is not found by the system.
Steps to reproduce
Ocorreu um erro inesperado no site. Por favor tente novamente mais tarde.
GuzzleHttp\Exception\ClientException: Client error: `GET https://cdn.datatables.net/plug-ins/1.10.20/i18n/Portuguese,%20Brazil.json` resulted in a `404 Not Found` response: 404 Not Found
Not Found (truncated...) in GuzzleHttp\Exception\RequestException::create() (line 113 of vendor/guzzlehttp/guzzle/src/Exception/RequestException.php).
Proposed resolution
we suggest DataTables support to make both URLs available on the server to avoid further errors, bur they refuse then.
Remaining tasks
User interface changes
API changes
Data model changes
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | patch_yasm_language.patch | 750 bytes | chicodasilva |
Comments
Comment #2
chicodasilva commentedHi,
I had the same problem. Forced the language to be "English" in this patch.
However if you want a specific language:
https://cdn.datatables.net/plug-ins/1.10.20/i18n/
Hope this can help.
Comment #3
oriol_e9gProbably I have to add a map with drupal langcodes and datatables languages, because datatables not use consistent langcodes and language names.
Comment #5
oriol_e9gI have added a map between drupal langcodes and last datatables available languages:
https://cdn.datatables.net/plug-ins/1.12.1/i18n/
It should now work in dev branch
Comment #6
oriol_e9g