My product has custom option type file, and I successfully place an order with file attached to my product, I want to do reorder only for custom option type file value, is it possible to copy custom option value from order item to cart item?

my phtml code:

<input id="logo<?=$data['option_id']?>"class="input-logo" name="options_<?=$data['option_id']?>_file" type="file"/>
<input style="display:none;" value="save_new" name="options_<?=$data['option_id']?>_file_action" type="text"/>

my add to cart code:

$params = array(
            'product' => $product->getId(),
            'qty' => 1,
            'form_key' => Mage::getSingleton('core/session')->getFormKey(),

$request = new Varien_Object();
try {
   $cart->addProduct($product->getId(), $request);
} catch (Exception $e) {

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.