OCS Submission Word Limit not working

We have defined submission Word Limit to 250 for all types of submissions but very long texts pass through inspite of the limit. No warning to the user and the long text is accepted.

We are on OCS version 2.3.6.0.

Has anyone else seen this problem?

Very greatful for any advice…

/Anders

Hi @andfa,

The OCS word limit is only approximate, because the abstract field allows HTML and the word limit requires stripping HTML coding out. Depending on how the abstract is constructed, it may appear shorter than it actually is once OCS strips out the HTML code.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher,
Thanks for your reply.

We have tried to reduce word limit to 20 words and then submitting pure text (no html) as long as 1300 words and even that long texts pass through without errors or warnings.

So we still think there is a problem here.

Best regards,
Anders

Hi @andfa,

Just to confirm, are you sure that the submission came into a track that has the word limit configured? Different word limits can be configured on a per-track basis.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi,
Yes, I am sure, at least how I understand the system.
I suppose you mean these configs, please see attached screen dump,

Best regards,
Anders

Ping!
Has anyone observed this problem?

/Anders

Hi @andfa,

Are you handy with PHP? I suspect this could be resolved pretty quickly if you can use a few error_log statements to determine what’s happening in the relevant section of code. See ocs/AuthorSubmitStep3Form.inc.php at ocs-2_3_6-0 · pkp/ocs · GitHub
for details.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi,
OK, I’ll give it a try.

Thanks,
Anders

I have tried some error_log statements now and this returns 0 (zero) for any abstract submitted.
Tried to debug a bit further but I can’t really get the abstract text or see where the code for function getAbstractWordCount() is located.

Hi @andfa,

That should be getting the word limit for the specific track that’s receiving the submission, which comes from the abstract_word_count column in the tracks table, if that helps.

Regards,
Alec Smecher
Public Knowledge Project Team

OK
All zeros there.

Hi @andfa,

Ah, I see the issue. You’ve configured word limits for each session type, but there are also word limits on each track. It looks like only the track word lengths are enforced during the submission process – the check doesn’t refer to the session length limits at all.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi,
We found the track limit setting now and that solved our problem.

:slight_smile:
Thanks for your support and patience.

Best regards,
Anders

1 Like