Skip to main content

clean-backup

Directories

Integration

Cache directory

Formula directory

CKEditor

<CKEditor>/plugins/ckeditor_wiris/cache

<CKEditor>/plugins/ckeditor_wiris/formulas

TinyMCE

<TinyMCE>/plugins/tiny_mce_wiris/cache

<TinyMCE>/plugins/tiny_mce_wiris/formulas

Froala

<Froala>/plugins/froala_wiris/cache

<Froala>/plugins/froala_wiris/formulas

On Java integration, these paths are provided by you on the configuration.ini file.

Freeing disk space: cleaning the image cache folder

If you want to free your disk space, you can empty the contents of the cache directory. Do not delete the folder but only remove its contents. The cache directory will be repopulated when users view the formulas.

Caution

Do not remove the formula directory if you are using the image mode because you will lose all your formulas and it will be difficult to recover them. Some plugins, like the Moodle one, do not have this requirement.

You can also clean the cache using the plugin's clean cache service (<plugin-path>/cleancache). This service cleans cache and formulas directories if a valid token is given. The token should be set in your configuration.ini file using wiriscleancachetoken variable, it needs to be MD5 encoded, for example: wiriscleancachetoken = 81dc9bdb52d04dc20036dbd8313ed055

The clean cache service can be accessed via GUI or called directly:

  • GUI mode: To activate this mode the variable wiriscleancachegui should be true. This mode allows the user to generate a valid md5 token and clean the cache (if wiriscleancachetoken has been declared).

  • Client mode: This mode is to access directly to the service (using wget, for example). The service needs two params: token and accept=application/json. The service returns a json that indicates if the cache has been successfully deleted or not. Parameters must be passed using POST.

Clean cache service specifications:

  • It only deletes empty folders, .ini, .txt .svg and .png files.

  • If image mode is active the .ini files are not removed.

Migrating your web server

If you want to migrate your web server, and you want to backup your formula images, you must also migrate the formula directory.

The formula directory contains the MathML of your website formula images. If these files are removed, you will lose your formulas. Note that the MathML is still stored in the <IMG> tag but it is useless for recovery purposes.