Internacionalización para español da error

Internacionalización para español da error

charly77charly77 Posts: 9Questions: 4Answers: 0

Yo tenía esto en mi página:
new DataTable('#myTable',{ language:{ url:'//cdn.datatables.net/plug-ins/2.0.2/i18n/es-ES.json', }, });
Hasta esta mañana me funcionaba bien. Esta tarde vi en los ejemplos del idioma la versión 2.0.6 y lo cambié, pero sigue dando el siguiente error:
"DataTables warning: table id=myTable - i18n file loading error. For more information about this error, please see https://datatables.net/tn/21"

This question has an accepted answers - jump to answer

Answers

  • kthorngrenkthorngren Posts: 20,425Questions: 26Answers: 4,794
    Answer ✓

    I just tried the URL:
    https://cdn.datatables.net/plug-ins/2.0.2/i18n/es-ES.json

    It is working. You might need to do some network troubleshooting to find the error. See this thread with the same error.

    Kevin

  • charly77charly77 Posts: 9Questions: 4Answers: 0

    Lo que no entiendo es por qué en el navegador Chrome sí que funciona y en Firefox no.

  • kthorngrenkthorngren Posts: 20,425Questions: 26Answers: 4,794

    What I don't understand is why in Chrome browser it works and not in Firefox.

    That's a good question. Could be a browser configuration issue. Have you looked at the browser's console for errors? Use the browser's network inspector tool to see if the response contains an error.

    Kevin

  • charly77charly77 Posts: 9Questions: 4Answers: 0
    edited May 19


    En la consola de Chrome, nada y en Firefox te mando adjunto un pantallazo con el cartel del error y la ventana de Red de la consola, donde aparecen dos errores de Datatables.
    He pensado que podría ser que en Firefox no guardo historial ni cookies, pero he probado al revés y tampoco se arregla.

  • kthorngrenkthorngren Posts: 20,425Questions: 26Answers: 4,794

    n the Chrome console, nothing and in Firefox I am attaching a screenshot with the error sign and the console's Network window, where two Datatables errors appear.
    I thought it might be that in Firefox I don't save history or cookies, but I've tried the other way around and it doesn't fix it either.

    Looks like you are getting the same CORS error as the thread I linked to. Its not a Datatables issue. Maybe this Mozilla doc will help.

    Kevin

Sign In or Register to comment.