Ask a question about this product - error validating characters

Started by Ventsi Genchev, September 03, 2017, 22:59:05 PM

Previous topic - Next topic

Ventsi Genchev

If the limit for asking a product question is a minimum of 50 and a maximum of 2000 characters, it is necessary to enter at least 51 characters to validate the form.
Accordingly, with the maximum number of symbols, the validation of the form is obtained with the 1999 symbols.

The simple solution is the following:
In the administration:
Question minimum length: 49 (minimum symbols minus 1)
Question maximum length: 2001 (maximum symbols plus 1)

root/templates/your_theme/html/com_virtuemart/askquestion/form.php
from:
$min = VmConfig::get('asks_minimum_comment_length', 50);
$max = VmConfig::get('asks_maximum_comment_length', 2000) ;
to:
$min = VmConfig::get('asks_minimum_comment_length', 50) +1;
$max = VmConfig::get('asks_maximum_comment_length', 2000) -1;
Audio Store:
https://vsystem.bg - Bulgarian language
https://vsystem.bg/en - English