- Posts: 16
- Thank you received: 0
Displaying version of product dimensions ?
15 years 6 months ago #12389
by pproject
Displaying version of product dimensions ? was created by pproject
Hi,
I would like to display the dimensions of product versions, but I could manage displaying the
dimensions of main product only.
Can you help inserting the right code?
Thanks.
I would like to display the dimensions of product versions, but I could manage displaying the
dimensions of main product only.
Can you help inserting the right code?
Thanks.
Please Log in or Create an account to join the conversation.
15 years 6 months ago #12416
by nicolas
Replied by nicolas on topic Re: Displaying version of product dimensions ?
Hi,
It's a lot more complicated because you need to refresh the display with the correct variant dimension...
What code did you use for the dimensions of the main product ?
It's a lot more complicated because you need to refresh the display with the correct variant dimension...
What code did you use for the dimensions of the main product ?
Please Log in or Create an account to join the conversation.
15 years 6 months ago #12427
by pproject
Replied by pproject on topic Re: Displaying version of product dimensions ?
I have duplicated the code of showing the weight of product, also duplicated the code at the
showing variants of weight, but that is not refreshing.(weight doing). If I set style=display:block
the list of variants displayed correctly, but refreshing does not work.
showing variants of weight, but that is not refreshing.(weight doing). If I set style=display:block
the list of variants displayed correctly, but refreshing does not work.
Please Log in or Create an account to join the conversation.
15 years 6 months ago #12456
by nicolas
Replied by nicolas on topic Re: Displaying version of product dimensions ?
In the file administrator/components/com_hikashop/types/characteristic.php you have the line:
var names = [\'id\',\'name\',\'code\',\'image\',\'price\',\'quantity\',\'description\',\'weight\',\'url\'];
you will need to add your new fields so that they are handled as well. So, for example if you have the id hikashop_product_dimension_main you would change that line into:
var names = [\'id\',\'name\',\'code\',\'image\',\'price\',\'quantity\',\'description\',\'weight\',\'url\',\'dimension\'];
Note that the modifications in that file will be overwritten when you update hikashop.
var names = [\'id\',\'name\',\'code\',\'image\',\'price\',\'quantity\',\'description\',\'weight\',\'url\'];
you will need to add your new fields so that they are handled as well. So, for example if you have the id hikashop_product_dimension_main you would change that line into:
var names = [\'id\',\'name\',\'code\',\'image\',\'price\',\'quantity\',\'description\',\'weight\',\'url\',\'dimension\'];
Note that the modifications in that file will be overwritten when you update hikashop.
Please Log in or Create an account to join the conversation.
15 years 6 months ago #12484
by pproject
Replied by pproject on topic Re: Displaying version of product dimensions ?
Thanks a lot Nicolas! Now that is working as a dream.
Please Log in or Create an account to join the conversation.
Time to create page: 0.188 seconds