title: remove item from cart for a given product id
body: <p>I am new in magento i have tried to remove items in cart when call this event checkout_cart_product_add_after when i try this code nothing can doing. any body help me. thanks.</p>
  
  <pre><code>$myProductId=20;
  $product = Mage::getModel('catalog/product')-&gt;setStoreId(Mage::app()-&gt;getStore()-&gt;getId())-&gt;load($myProductId);
  $quote =  Mage::getSingleton('checkout/session')-&gt;getQuote();
  $cartItems = $quote-&gt;getItemByProduct($product);
  if ($cartItems) {  $quote-&gt;removeItem($cartItems-&gt;getId())-&gt;save();}
  </code></pre>