Report any technical problems you discover and discuss solutions.

Xerte offline does not work

Plus d'informations
il y a 6 ans 3 mois #6509 par victor777
Réponse de victor777 sur le sujet Xerte offline does not work
Dear Tom

The file is here

drive.google.com/file/d/1omV3myNz7SS8taRkDK-joevXFocjM9Sl/view?usp=sharing

Thanks

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 6 ans 3 mois #6510 par tom
Réponse de tom sur le sujet Xerte offline does not work
Hmmm. There is still someting fishy going on with the language files. It seems that the byte in the xml file, to indicate that the content is utf-8 is not particularly liked by Chrome.

If I strip that out, then it seems to work.

I don't know which version of Xerte online toolkits you use, but you can try the following:

Make a backup of modules/xerte/parent_templates/Nottingham/common_html5/js/xenith.js

Edit that file, and search for 'langxmlstr'. You should see a code fragmant like this:
Code:
// function gets data from language file function x_getLangData(lang) { if (typeof langxmlstr != 'undefined') { // We have a off-line object with the language definition in a string // Convert to an XML object and continue like before x_languageData = $($.parseXML(langxmlstr)).find("language"); x_setUp(); }

Insert the following line right after the comment that starts with //Convert
Code:
langxmlstr = langxmlstr.substr(langxmlstr.indexOf("<"), langxmlstr.lastIndexOf(">") + 1);

So the resulting fragment is as follows:
Code:
// function gets data from language file function x_getLangData(lang) { if (typeof langxmlstr != 'undefined') { // We have a off-line object with the language definition in a string // Convert to an XML object and continue like before langxmlstr = langxmlstr.substr(langxmlstr.indexOf("<"), langxmlstr.lastIndexOf(">") + 1); x_languageData = $($.parseXML(langxmlstr)).find("language"); x_setUp(); }

Of course you can check that in your project, by editing the xenith.js in there first and see if it works for you.

I attached a fixed xenith.js, that I patched from your zip file. You should also be able to copy that in your xerte installation.
Pièces jointes :

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 6 ans 3 mois #6511 par victor777
Réponse de victor777 sur le sujet Xerte offline does not work
thanks a lot for all your help my friend.
Everything was perfect after that fixed code.
Welcome to Medellín Colombia whenever you like to come.

Connexion ou Créer un compte pour participer à la conversation.

Modérateurs: ronmjultenJohnSmith
Temps de génération de la page : 0.132 secondes
Copyright © 2026 The Xerte Project.
Xerte logo Apereo logo OSI Logo