You are viewing the PKP Support Forum | PKP Home Wiki

Increasing length of language metadata

OCS development discussion, enhancement requests, third-party patches and plug-ins.

Moderators: jmacgreg, michael

Forum rules
Developer Resources:

Documentation: The OJS Technical Reference and the OJS API Reference are both available from the OJS Documentation page. While these are OJS-specific, the OCS codebase is similar enough to OJS they should be of help. There is also an [url=http://pkp.sfu.ca/ocs_documentation[/url]OCS Documentation[/url] page with some more general documentation that might also be of interest.

Git: You can access our public Git Repository here. Comprehensive Git usage instructions are available on the wiki.

Bugzilla: You can access our Bugzilla report tracker here.

Search: You can use our Google Custom Search to search across our main website, the support forum, and Bugzilla.

Questions and discussion are welcome, but if you have a workflow or usability question you should probably post to the OCS Conference Support and Discussion subforum; if you have a technical support question, try the OCS Technical Support subforum.

Increasing length of language metadata

Postby sandyg » Wed Jul 17, 2013 5:39 pm


I've been asked to modify our local OJS installation (currently 2.3.6) to increase the length of the article metadata language field, which is currently limited to 10 characters. We have a journal that will be publishing in 5 languages, and our OJS librarian would like to be able to include the codes for all 5 in this field.

Looking at the source, it appears the only change required would be to:


to increase the value of the attribute "maxlength=10" applied to that input field.

The second change would be to the database structure, increasing the width of the 'articles.language' field, with a corresponding update to the XML schema files in the dbscripts folder.

I've recently inherited our OJS install and haven't done much work with the system yet, so I'm just hoping to get confirmation that these proposed changes should achieve the desired effect. Have I missed anything important here?

Alternatively, would this be an appropriate enhancement request for a future release?

Thanks... Sandy
Posts: 6
Joined: Wed Jul 17, 2013 4:53 pm

Re: Increasing length of language metadata

Postby asmecher » Thu Jul 18, 2013 9:35 am

Hi Sandy,

That's exactly the procedure I'd suggest. One minor addition: make the schema change in the DB descriptor file, dbscripts/xml/ocs_schema.xml. Otherwise, if you ever sync the descriptor against the DB, you risk chopping the column back down to 10 characters (and any data along with it). For upgrades, we tend to use a diff/patch procedure to migrate any modifications to new releases; using that process the schema change will also be propagated.

Alec Smecher
Public Knowledge Project Team
Posts: 10015
Joined: Wed Aug 10, 2005 12:56 pm

Return to OCS Development

Who is online

Users browsing this forum: No registered users and 1 guest