Answered: Where is configurations of max length of the categories?

Post date: 2021-04-13 23:51:19
Views: 44

The length of category names is limited by the size of the title field in the respective database table:

MariaDB dbname]> describe qa_categories;
+------------+----------------------+------+-----+---------+----------------+
| Field      | Type                 | Null | Key | Default | Extra          |
+------------+----------------------+------+-----+---------+----------------+
| categoryid | int(10) unsigned     | NO   | PRI | NULL    | auto_increment |
| parentid   | int(10) unsigned     | YES  | MUL | NULL    |                |
| title      | varchar(80)          | NO   |     | NULL    |                |
| tags       | varchar(200)         | NO   |     | NULL    |                |
| content    | varchar(800)         | NO   |     |         |                |
| qcount     | int(10) unsigned     | NO   |     | 0       |                |
| position   | smallint(5) unsigned | NO   |     | NULL    |                |
| backpath   | varchar(804)         | NO   | MUL |         |                |
+------------+----------------------+------+-----+---------+----------------+

The size limit is set when the table is created and the value for the limit is defined in qa-include/db/maxima.php:

$maximaDefaults = array(
  ...
  'QA_DB_MAX_CAT_PAGE_TITLE_LENGTH' => 80,
  ...
};

Please click Here to read the full story.
 
Other Top and Latest Questions:
Iran war threatens $11.7 trillion global travel industry as passengers get caught in crossfire
Google joins Microsoft in telling users Anthropic is still available outside defense projects
You can buy gold on Amazon — but should you?
Dow falls 450 points, posts worst week in nearly a year as oil tops $90, jobs data disappoints: Live updates
Middle-income homebuyers have $30,000 more buying power than a year ago, research finds. It's still not enough
Guided tours of museums and sights in Paris?
LUMIÈRE!
Book: Elantris
FDA vaccine head will step down in April after string of controversial decisions
'E-shaped' economy is replacing a K-shaped one in 2026, economist says: The middle class is 'spending in a nervous way' now