Hi,
Thanks for your post in that section.
In the HikaMarket product class (administrator/components/com_hikamarket/classes/product.php), you will find that code
$product->product_description = JRequest::getVar('product_description','','','string',JREQUEST_ALLOWRAW);
if((int)$config->get('vendor_safe_product_description', 1)) {
$safeHtmlFilter = JFilterInput::getInstance(null, null, 1, 1);
$product->product_description = $safeHtmlFilter->clean($product->product_description, 'string');
}
You can replace that code by
$product->product_description = JRequest::getVar('product_description','','','string',JREQUEST_ALLOWRAW);
if((int)$config->get('vendor_safe_product_description', 1)) {
$safeHtmlFilter = JFilterInput::getInstance(null, null, 1, 1);
$product->product_description = $safeHtmlFilter->clean($product->product_description, 'string');
}
$strip_tags = $config->get('vendor_striptags_product_description', '');
if(!empty($strip_tags)) {
$product->product_description = strip_tags($product->product_description, $strip_tags);
}
So you will have a new hidden setting to completely remove all HTML tags in the product description when a vendor edit a product.
You can also replace in the same file
$product->product_description = JRequest::getVar('product_variant_description','','','string',JREQUEST_ALLOWRAW);
$safeHtmlFilter = JFilterInput::getInstance(null, null, 1, 1);
$product->product_description = $safeHtmlFilter->clean($product->product_description, 'string');
By
$product->product_description = JRequest::getVar('product_variant_description','','','string',JREQUEST_ALLOWRAW);
if((int)$config->get('vendor_safe_product_description', 1)) {
$safeHtmlFilter = JFilterInput::getInstance(null, null, 1, 1);
$product->product_description = $safeHtmlFilter->clean($product->product_description, 'string');
}
$strip_tags = $config->get('vendor_striptags_product_description', '');
if(!empty($strip_tags)) {
$product->product_description = strip_tags($product->product_description, $strip_tags);
}
So the variants will also have that hidden setting available.
Please note that the patch will be integrated into next HikaMarket release.
For more details about "strip_tags" :
php.net/manual/en/function.strip-tags.php
Regards,