Skip to main content

Add Multiple Products to carts

More
12 years 3 months ago - 12 years 3 months ago #163563 by angelfila
-- url of the page with the problem -- : N/A [Currently in local development]
-- HikaShop version -- : 2.3.1
-- Joomla version -- : 3.3.1
-- PHP version -- : 5.3.28
-- Browser(s) name and version -- : Chrome Version 35.0.1916.153 m


How do I allow user to multiple select items with the amount of qty needed and submit to cart?
Kindly refer to attachment for Sample.
Last edit: 12 years 3 months ago by angelfila.

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163574 by nicolas
Hi,

You can set the "Display the quantity field on the product page" option of the configuration to "global on listings" in the Hikashop configuration.
Then, if you turn on the "display add to cart button" option of your products listings, you'll get one quantity field per product with a main add to cart button.

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163664 by angelfila
It work wonderful. Is there anyway I could set the qty by default to 1?

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163721 by angelfila
I manage to resolved this. :)

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163665 by Xavier
Hi,

You have to edit the view "product / add_to_cart_listing" and edit the code line:
Code:
<input id="hikashop_listing_quantity_<?php echo $this->row->product_id;?>" type="text" style="width:40px;" name="data[<?php echo $this->row->product_id;?>]" class="hikashop_listing_quantity_field" value="0" />
To replace value="0" by vlaue="1"

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163759 by angelfila
I have added the following "custom field" code to checkout>cart.

<td>
<?php echo $this->row->subject; ?>
</td>


The issue I am facing now is that the 1st line of subject is not showing, as shown in "checkout_cart_image.PNG"

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163768 by Mohamed Thelji
Hello,
And did you set a value for the "subject" custom field of the product "EnglishWise : Conprehension1" ?

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163855 by angelfila
Yes i did, it is showing up at producting listing with the same code that i add in.

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #163856 by Jerome
Hi,

Sure.
As you can see in the code, the variable "$this->row" is set below your code, just before the display of the price.
You have to use "$row->subject" and not "$row->subject".

Regards,

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Please Log in or Create an account to join the conversation.

Time to create page: 0.140 seconds
Powered by Kunena Forum