|
Hello there,
I have in my product view some extra options. These option are showed now but it messed up the layout when no extra options are available for a certain product. When I put the code somewhere else in the ordering of code the layout is good when no extra options are added but messed up when there are extra options.
So I thought to use a IF statement to look if there are any options, if not show the code earlier. But the variable I need is inside a child which is called within this piece of code. How can I get the variable out of it? Hope it’s clear, here is the code that add’s the extra options:
<div class="add-to-box"><?php if (!$this->hasOptions()):?>
<div>
<?php echo $this->getChildHtml('product_type_data') ?>
<?php echo $this->getChildHtml('emjainteractive_externalproduct_link') ?>
<?php if($_product->isSaleable()): ?>
<?php echo $this->getChildHtml('addtocart') ?>
<?php endif; ?>
</div>
<?php echo $this->getChildHtml('extra_buttons') ?>
<?php endif; ?></div>
The variable I need is within product_type_data and called $_hasAssociatedProducts
Thanks in advance!
|