VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: kiasati on December 27, 2017, 16:27:06 PM

Title: where in database do custom fields store?
Post by: kiasati on December 27, 2017, 16:27:06 PM
Hi
I have some custom fields in "Editor" type to show some text in product page.
but it has character limit. how can i increase the limit or remove the limitation?
where in database do custom fields store?
Title: Re: where in database do custom fields store?
Post by: Studio 42 on December 28, 2017, 00:49:39 AM
Hi, the limit is  2500 char for customfield_value.
The table is #___virtuemart_product_customfields
You should not change this because you can loose your changes on update Virtuemart and this can slowdown your shop if you need it to search in customfields(2500 is already big).
I have this type of field in my plugin, if you need a simple editor. See My Addon (https://shop.st42.fr/en/products/shortcodes.htm) and parameters (https://shop.st42.fr/en/shorcodes-english-doc#editor), it use the params and have a maximum length of 65,535 char(minus params name) this is more then the product_desc itself, limited to 18400 char for the same reason as custom value.
Title: Re: where in database do custom fields store?
Post by: kiasati on December 28, 2017, 16:39:17 PM
Quote from: Studio 42 on December 28, 2017, 00:49:39 AM
Hi, the limit is  2500 char for customfield_value.
The table is #___virtuemart_product_customfields
You should not change this because you can loose your changes on update Virtuemart and this can slowdown your shop if you need it to search in customfields(2500 is already big).
I have this type of field in my plugin, if you need a simple editor. See My Addon (https://shop.st42.fr/en/products/shortcodes.htm) and parameters (https://shop.st42.fr/en/shorcodes-english-doc#editor), it use the params and have a maximum length of 65,535 char(minus params name) this is more then the product_desc itself, limited to 18400 char for the same reason as custom value.
Thanks a lot for answering :)
so i thought of another solution. i'll make another custom field and show it right after the first one.

another problem:
the type of this custom field is "Editor".
but in the backend the entry box is not an editor. it's an simple text box to put code in it. what is the problem and how can i fix this?
Title: Re: where in database do custom fields store?
Post by: Studio 42 on December 28, 2017, 16:45:47 PM
I wrote my plugin to solve all this problem in Virtuemart.
Sometime this is a Javascript problem or you need to reload the product form.