I don't want to remove the cart fully from my header, only the mini-cart that pops up when you hover the cart.
If someone knows how to do this, please help me, I would really appreciate it. It is driving my insane!

My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
I didn't want to remove the cart fully out of the header, only the mini cart pop up when the cart is hoveredIP_CAM wrote:...or then, just remove the Cart out of the Header!
Thanks very much, that has workeddeepvision wrote:It can be done with cssCode: Select all
div#cart .content { display: none !important; }
Code: Select all
<script>
$(function(){
$('#cart').on('click',function(){
window.location = '/index.php?route=checkout/cart'
});
});
</script>
My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
RemovingIP_CAM wrote:just to complete it, removing the small cart from the header does not mean, to remove the Cart, or links to it, from anywhere else!
Ernie
Code: Select all
<?php echo $cart; ?>
Code: Select all
<div class="journal-cart j-min xs-100 sm-100 md-33 lg-25 xl-25">
<div id="cart">
<div class="heading" >
<a><span id="cart-total">BAG (0) - £0.00</span><i></i></a>
</div>
<div class="content">
<div class="cart-wrapper">
<div class="empty">Your shopping bag is empty!</div>
</div>
</div>
</div> </div>
My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Code: Select all
<div id="cart">
...
<div>
Code: Select all
<div id="cart">
<div class="heading" >
<a><span id="cart-total"><?php echo $text_items; ?></span><i></i></a>
</div>
<div class="content">
<div class="cart-wrapper">
<?php if ($products || $vouchers) { ?>
<div class="mini-cart-info">
<table>
<?php foreach ($products as $product) { ?>
<tr>
<td class="image"><?php if ($product['thumb']) { ?>
<a href="<?php echo $product['href']; ?>"><img src="<?php echo $product['thumb']; ?>" alt="<?php echo $product['name']; ?>" title="<?php echo $product['name']; ?>" /></a>
<?php } ?></td>
<td class="name"><a href="<?php echo $product['href']; ?>"><?php echo $product['name']; ?></a>
<div>
<?php foreach ($product['option'] as $option) { ?>
- <small><?php echo $option['name']; ?> <?php echo $option['value']; ?></small><br />
<?php } ?>
<?php if (isset($product['recurring'])) : /* v156 compatibility */ ?>
<?php if ($product['recurring']): ?>
- <small><?php echo $text_payment_profile ?> <?php echo $product['profile']; ?></small><br />
<?php endif; ?>
<?php endif; /* end v156 compatibility */ ?>
</div></td>
<td class="quantity">x <?php echo $product['quantity']; ?></td>
<td class="total"><?php echo $product['total']; ?></td>
<td class="remove"><i onclick="(getURLVar('route') == 'checkout/cart' || getURLVar('route') == 'checkout/checkout') ? location = 'index.php?route=checkout/cart&remove=<?php echo $product['key']; ?>' : $('#cart').load('index.php?route=module/cart&remove=<?php echo $product['key']; ?>' + ' #cart > *');"></i></td>
</tr>
<?php } ?>
<?php foreach ($vouchers as $voucher) { ?>
<tr>
<td class="image"></td>
<td class="name"><?php echo $voucher['description']; ?></td>
<td class="quantity">x 1</td>
<td class="total"><?php echo $voucher['amount']; ?></td>
<td class="remove"><i onclick="(getURLVar('route') == 'checkout/cart' || getURLVar('route') == 'checkout/checkout') ? location = 'index.php?route=checkout/cart&remove=<?php echo $voucher['key']; ?>' : $('#cart').load('index.php?route=module/cart&remove=<?php echo $voucher['key']; ?>' + ' #cart > *');"></i></td>
</tr>
<?php } ?>
</table>
</div>
<div class="mini-cart-total">
<table>
<?php foreach ($totals as $total) { ?>
<tr>
<td class="right"><b><?php echo $total['title']; ?>:</b></td>
<td class="right"><?php echo $total['text']; ?></td>
</tr>
<?php } ?>
</table>
</div>
<div class="checkout"><a class="button" href="<?php echo $cart; ?>"><?php echo $text_cart; ?></a> <a class="button" href="<?php echo $checkout; ?>"><?php echo $text_checkout; ?></a></div>
<?php } else { ?>
<div class="empty"><?php echo $text_empty; ?></div>
<?php } ?>
</div>
</div>
</div>
My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
just to make clear, I'm takling about the DEFAULT THEME only, the code may look different by use of other Themes!deepvision wrote:I agree with IP_CAM ....... Because it would not work.
My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
deepvision wrote:Yesterday I posted the code to solve the problem with clicks.
Actually I posted it two days ago
Code: Select all
<script>
$(function(){
$('#cart').on('click',function(){
window.location = '/index.php?route=checkout/cart'
});
});
</script>
Just done that and it worked, thanks very much. You did mean footer.tpl, and not head, right?deepvision wrote:Can be added to the
/catalog/view/theme/journal2/template/common/footer.tpl
Users browsing this forum: No registered users and 6 guests