Skip to main content
added 56 characters in body
Source Link
laketuna
  • 6.9k
  • 7
  • 40
  • 82

You need to move that bracket out and place it after $htmlItem. Like this..

$cart_items = Mage::getSingleton('checkout/session')->getQuote()->getAllVisibleItems();
foreach($cart_items as $items) {
    $qtyr = $items->getQty();

    Mage::log($items->getSku()); // EXAMINE THIS

    $htmlItem .= ' <div class="qty-btngroup">'
        . '<input type="text" class="input-text qty" maxlength="12" title="Qty" size="4" value="'.$qtyr.'" name="" readonly="readonly">'
        . ' </div>';
}  // THIS GOES HERE
$_response = Mage::getModel('ajaxminicart/response')
    ->setCartitem($html);

You need to move that bracket out and place it after $htmlItem. Like this..

$cart_items = Mage::getSingleton('checkout/session')->getQuote()->getAllVisibleItems();
foreach($cart_items as $items) {
    $qtyr = $items->getQty();

    $htmlItem .= ' <div class="qty-btngroup">'
        . '<input type="text" class="input-text qty" maxlength="12" title="Qty" size="4" value="'.$qtyr.'" name="" readonly="readonly">'
        . ' </div>';
}  // THIS GOES HERE
$_response = Mage::getModel('ajaxminicart/response')
    ->setCartitem($html);

You need to move that bracket out and place it after $htmlItem. Like this..

$cart_items = Mage::getSingleton('checkout/session')->getQuote()->getAllVisibleItems();
foreach($cart_items as $items) {
    $qtyr = $items->getQty();

    Mage::log($items->getSku()); // EXAMINE THIS

    $htmlItem .= ' <div class="qty-btngroup">'
        . '<input type="text" class="input-text qty" maxlength="12" title="Qty" size="4" value="'.$qtyr.'" name="" readonly="readonly">'
        . ' </div>';
}  // THIS GOES HERE
$_response = Mage::getModel('ajaxminicart/response')
    ->setCartitem($html);
Source Link
laketuna
  • 6.9k
  • 7
  • 40
  • 82

You need to move that bracket out and place it after $htmlItem. Like this..

$cart_items = Mage::getSingleton('checkout/session')->getQuote()->getAllVisibleItems();
foreach($cart_items as $items) {
    $qtyr = $items->getQty();

    $htmlItem .= ' <div class="qty-btngroup">'
        . '<input type="text" class="input-text qty" maxlength="12" title="Qty" size="4" value="'.$qtyr.'" name="" readonly="readonly">'
        . ' </div>';
}  // THIS GOES HERE
$_response = Mage::getModel('ajaxminicart/response')
    ->setCartitem($html);