+1 vote
in General by (14.2k points)

When I post an answer of length > 12,000 characters, Q2A CMS gives the following error:

Maximum length is 12000 characters

How can I fix this error?

1 Answer

0 votes
by (22k points)

Edit the file qa-include/db/maxima.php and change the value of the variable QA_DB_MAX_CONTENT_LENGTH from 12000 to a bigger value, e.g 20000

    'QA_DB_MAX_CONTENT_LENGTH' => 20000, 

This file has maximum values for many variables. You can change them as per your requirements.

    'QA_DB_MAX_EMAIL_LENGTH' => 80,
    'QA_DB_MAX_HANDLE_LENGTH' => 20,
    'QA_DB_MAX_TITLE_LENGTH' => 800,
    'QA_DB_MAX_CONTENT_LENGTH' => 18000,
    'QA_DB_MAX_FORMAT_LENGTH' => 20,
    'QA_DB_MAX_TAGS_LENGTH' => 800,
    'QA_DB_MAX_NAME_LENGTH' => 40,
    'QA_DB_MAX_WORD_LENGTH' => 80,
    'QA_DB_MAX_CAT_PAGE_TITLE_LENGTH' => 80,
    'QA_DB_MAX_CAT_PAGE_TAGS_LENGTH' => 200,
    'QA_DB_MAX_CAT_CONTENT_LENGTH' => 800,
    'QA_DB_MAX_WIDGET_TAGS_LENGTH' => 800,
    'QA_DB_MAX_WIDGET_TITLE_LENGTH' => 80,
    'QA_DB_MAX_OPTION_TITLE_LENGTH' => 40,
    'QA_DB_MAX_PROFILE_TITLE_LENGTH' => 40,
    'QA_DB_MAX_PROFILE_CONTENT_LENGTH' => 8000,
    'QA_DB_MAX_CACHE_AGE' => 86400,
    'QA_DB_MAX_BLOB_FILE_NAME_LENGTH' => 255,
    'QA_DB_MAX_META_TITLE_LENGTH' => 40,
    'QA_DB_MAX_META_CONTENT_LENGTH' => 8000,

...