Our component supports adding products to the cart by a link from anywhere in your shop or from outside the shop, you can configure this One Page Checkout extension to delete content of the cart before adding a product from url parameters. For an example, have a look on our demo sites.
This extension was firsly created for Magazine subscription where it was the only product on the site. It is particularly usefull for event registration or similarly. The link to the cart can be used from external sites if you are having a specialized marketing site.
In One Page Checkout 2 this feature has extended properties which can be set at the General tab of OPC backend configuration:
Available options:
Not enabled: This option will turn off the functionality of this feature.
Delete cart content and set link quantity: This option will clear all products from the cart before the one set in the link is added. It will strictly set the quantity of the provided link.
Do not increment quantity and do not delete cart: This option will not add quantity if the product is already found in the cart content. The quantity will not be changed and will remain at the previous state.
Increment quantity and do not delete cart: If the link is accessed twice, the quantity of the product in the link is added twice. Other products will not get affected.
How to create the links
To add quantity of 10 pieces for product with id 270 you can create this sort of link:
OPC1 for Virtuemart 1 style:
/index.php?option=com_virtuemart&page=shop.cart&add_id[]=270&qadd_270=10
/index.php?option=com_virtuemart&page=shop.cart&add_id=270&qadd=10
OPC2 for Virtuemart 2 style:
/index.php?option=com_virtuemart&view=cart&add_id[]=270&qadd_270=10
/index.php?option=com_virtuemart&view=cart&add_id=270&qadd=10
OR (for multiple products with multiple quantities):
Will add 10 pieces of product with id 270 and 5 of product with id 280
OPC1 for Virtuemart 1
/index.php?option=com_virtuemart&page=shop.cart&add_id[]=270&qadd_270=10&add_id[]=280&qadd_280=5
OPC2 for Virtuemart 2
/index.php?option=com_virtuemart&view=cart&add_id[]=270&qadd_270=10&add_id[]=280&qadd_280=5
Comments
is it possible to get child products directelly via e-mail-link into the cart?
Thanks forward.
Best Regards,
Björn
I want to add a custom price with this url, is it possible?
Thanks a lot
Giovani
best regards, stan
RSS feed for comments to this post