In templates/tpl_shopping_cart_default.php I have this:
Code:
<?php if ($messageStack->size('shopping_cart') > 0) echo $messageStack->output('shopping_cart'); ?>
Which outputs the following:
Code:
<div class="messageStackCaution larger"><img src="includes/templates/alt_jungle/images/icons/warning.gif" alt="Warning" title=" Warning " width="20" height="20" /> Please update your order ...<br />Product Name: Test Product<br />We are sorry but this product has been removed from our inventory at this time.<br />This item has been removed from your shopping basket.<br /></div>
Now I'd like to wrap that inside an addition <div> without having that extra <div> show when the error message isn't there.
So obviously,
Code:
<div class="my_extra_div"><?php if ($messageStack->size('shopping_cart') > 0) echo $messageStack->output('shopping_cart'); ?></div>
doesn't work as the <div> will always be displayed.
Code:
<?php if ($messageStack->size('shopping_cart') > 0) echo '<div class="my_extra_div">' . $messageStack->output('shopping_cart') . '</div>; ?>
Doesn't work either.. it seems the error is generated before the echo, and I'm useless at php.
Where are the <div="messageStackCaution Larger"> being generated?
Bookmarks