Go to app\design\frontend\base\default\template\checkout\onepage\link.phtml
Put this code in this page
<?php if ($this->isPossibleOnepageCheckout()):?>
<?php if(Mage::helper('checkout/cart')->getCart()->getItemsQty() >= 3):?>
<button type="button" title="<?php echo $this->__('Proceed to Checkout') ?>" class="button btn-proceed-checkout btn-checkout<?php if ($this->isDisabled()):?> no-checkout<?php endif; ?>"<?php if ($this->isDisabled()):?> disabled="disabled"<?php endif; ?> onclick="window.location='<?php echo $this->getCheckoutUrl() ?>';"><span><span><?php echo $this->__('Proceed to Checkout') ?></span></span></button>
<?php else:?>
<font style="color:red;">You must order a quantity of 3 or more to proceed.</font>
<?php endif?>
<?php endif?>
Then put this code into header.phtml page
<input type="hidden" id="get_cart" value="<?php echo Mage::helper('checkout/cart')->getCart()->getItemsQty(); ?>" />
<script type='text/javascript'>
jQuery(document).ready(function() {
if(document.getElementById("get_cart").value < 3) {
jQuery(".top-link-checkout").attr("href", "javascript:void(0);")
}
});
</script>
Then enjoy!!!!!!!!!!!!!!
Put this code in this page
<?php if ($this->isPossibleOnepageCheckout()):?>
<?php if(Mage::helper('checkout/cart')->getCart()->getItemsQty() >= 3):?>
<button type="button" title="<?php echo $this->__('Proceed to Checkout') ?>" class="button btn-proceed-checkout btn-checkout<?php if ($this->isDisabled()):?> no-checkout<?php endif; ?>"<?php if ($this->isDisabled()):?> disabled="disabled"<?php endif; ?> onclick="window.location='<?php echo $this->getCheckoutUrl() ?>';"><span><span><?php echo $this->__('Proceed to Checkout') ?></span></span></button>
<?php else:?>
<font style="color:red;">You must order a quantity of 3 or more to proceed.</font>
<?php endif?>
<?php endif?>
Then put this code into header.phtml page
<input type="hidden" id="get_cart" value="<?php echo Mage::helper('checkout/cart')->getCart()->getItemsQty(); ?>" />
<script type='text/javascript'>
jQuery(document).ready(function() {
if(document.getElementById("get_cart").value < 3) {
jQuery(".top-link-checkout").attr("href", "javascript:void(0);")
}
});
</script>
Then enjoy!!!!!!!!!!!!!!