News:

Support the VirtueMart project and become a member

Main Menu

Customising add to cart button in order-history page

Started by phil147, July 15, 2020, 16:42:51 PM

Previous topic - Next topic

phil147

Hi,
not sure where lese to post this question...
Im using VM 3.2.12 and JM 3.9.15

I'm trying to put function to add previous ordered items to cart from order-history page. (on test local host)

When use is logged in and at page /order-history  , I have inserted following code in details_items.php

$productModel = VmModel::getModel('Product');
$this->product = $productModel->getProduct ($product_id,'1');
echo shopFunctionsF::renderVmSubLayout('addtocart',array('product'=>$this->product));

So far so good, function displays add to cart button and correct product is added to cart.

My question is , when add to cart is actioned, why doesnt the window pop up happen (padded.php) , instead it opens the cart

I want the add to cart pop up window opened and remain on same view of order-history

Thanks
Phil

jjk

I don't know how to solve your remaining problem. Just wanted to mention that 'Webkul' offers a plugin which might be of interest to you. Search for 'Joomla Virtuemart Buy Again' in Google.
Non-English Shops: Are your language files up to date?
http://virtuemart.net/community/translations