News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Child products display under main product

Started by millennium, December 22, 2011, 17:50:45 PM

Previous topic - Next topic

millennium

Hi,

wanted to know is the a possibility to show children products as somekind of table as it was in virtuemart 1.1.9 (under main product), and under them related products.
Regards,
Andrius

J1.5.25 VM2

PRO

I dont use child products, but the layout looks like it can be constomized  in productdetails/tmpl/default.php

<?php foreach ($this->product->customsChilds as $field)

millennium

#2
thank you for an answer, i'm not very skilled in php but i'll give it a try,
i just don't understand the way i should use custom fields what i want to achieve a view in product detail:

main product
and under it
child products in sunch a table
<table width="90%" border="1">
  <tr>
    <td width="30%">SKU number</td>
    <td width="37%">Description</td>
    <td width="33%">Ad to cart</td>
  </tr>
  <tr>
    <td>123</td>
    <td>Description about product 123</td>
    <td>Add to cart button</td>
  </tr>
  <tr>
    <td>124</td>
    <td>Description about product 124</td>
    <td>Add to cart button</td>
  </tr>
  <tr>
    <td>125</td>
    <td>Description about product 124</td>
    <td>Add to cart button</td>
  </tr>
</table>

 


and under this table i would like to see related products to this?

Do you think it's possible?
Regards,
Andrius

J1.5.25 VM2

PRO

ok 1st, do the child products show up at all now?

what does it look like?

millennium

Hi

i get Warning: Invalid argument supplied for foreach() in ....html\com_virtuemart\productdetails\default.php on line 627 when i put "<?php foreach ($this->product->customsChilds as $field)?>" at the end of default.php
Regards,
Andrius

J1.5.25 VM2

PRO

thats because the code is already in the page right under the add to cart.

ARe the child products showing now? 

millennium

#6
no, they are not. :(

forgot to mention


Notice: Undefined property: stdClass::$customsChilds in ...\html\com_virtuemart\productdetails\default.php on line 627

Warning: Invalid argument supplied for foreach() in ...\html\com_virtuemart\productdetails\default.php on line 627
Regards,
Andrius

J1.5.25 VM2

PRO

because u need to take out the code you added.

Its already in the product page

millennium

Regards,
Andrius

J1.5.25 VM2

PRO

i do not know because i dont use child products.

many other do, im sure they will chime in

millennium

Thanks for your help
I surely hope somebody will help, this feature could help to have a clean looking list table style of child products.
Regards,
Andrius

J1.5.25 VM2

millennium

#11
Hi everybody,

maybe someone knows how to achieve that?

Mod edit: further bump message removed.   http://forum.virtuemart.net/index.php?topic=68489.0
Regards,
Andrius

J1.5.25 VM2