Hi all,
Sorry for the delay in responding; this thread looks like it slipped through the cracks. You can find almost all language codes in the various "locale" columns of the database (see the schema descriptors referenced in dbscripts/xml/install.xml for the OJS schema). You can update those columns e.g. from en_US to fr_CA to change the designation of existing content from English to French. For Article settings, i.e. titles, abstracts, and other multilingual content associated with articles, that would be:
- Code: Select all
UPDATE article_settings SET locale = 'fr_CA' WHERE locale = 'en_US';
Note that there is a unique index on article_id, setting_name, and locale, meaning that if you already have e.g. French abstracts entered somewhere, the update will fail on a duplication error and you'll have to resolve those first.
The above example is for article data, such as abstracts and titles; journal-level metadata (titles, etc.) are in journal_settings, issue-level metadata is in issue_settings, etc.
The only exception to this pattern is some of the journal settings that are structured as objects. You can find these with the following query:
- Code: Select all
SELECT * FROM journal_settings WHERE setting_type = 'object';
Look for language codes (e.g. en_US) in those and replace them as needed.
You may have to flush your caches after updating these settings (e.g. for journal-level settings) before the changes will be reflected in the application. The easiest way to do that is to remove all .php (and possibly .html) files from the cache/ subdirectory.
Regards,
Alec Smecher
Public Knowledge Project Team