Questions tagged [cart]

A web cart or online shopping cart is a web app used to shop online. **For questions related to CART -- Classification and Regression Trees -- use the tag [cart-analysis], or consider whether the topic is more appropriate for Cross Validated or Data Science Stack Exchange**

-5
votes
0answers
15 views

Empty WooCommerce cart after I click checkout button [on hold]

On my website I use the prosociate plugin which is used to fetch products from Amazon. The checkout button redirects to Amazon's website. The issue I am facing is that I want to empty the cart after ...
-4
votes
0answers
22 views

How to add items to cart by using ruby checkboxes

I am trying to add a selection of items to cart based on their check box status.For the view I have: <% @ingredients.each do |ingredient| %><%=check_box_tag(:ingredient_id) %> <%...
0
votes
0answers
14 views

How do I edit more than 1 rpart.plot() split label?

Is there a way to change CART decision tree split labels without changing the original variable names and/or value labels in the data frame? I've tried using this split.function I copied out of the "...
-1
votes
0answers
17 views

Woocommerce WC()->cart->add_to_cart() is not working for visitors but works for logged in users

I am developing the plugin where i am adding the products to cart by for loop as shown in the codeglobal $woocommerce;for ($x=0; $x < $_REQUEST['numberofproduct']; $x++) {$cart_item_data['...
0
votes
1answer
15 views

Woocommerce Cart not clearing

I know there will be this type of questions but i have tried almost all options without luck so i'm asking here.I have issue that cart is not empty in woocommerce after order completed and also some ...
-1
votes
0answers
16 views

Woocommerce cart page grouped products parent link and image

In Woocommerce cart page I am trying to display the grouped product parent image as the thumb and also have the grouped parent as a link to the parent product.This is how the cart looks:The first ...
0
votes
2answers
42 views

Add a percentage Fee with a fixed Fee to Woocommerce

In Woocommerce, I would like to add 3% processing fee plus 30 cent “fixed” fee to the checkout page.I have managed to add the processing fee, using the code mentioned below:add_action( '...
2
votes
1answer
39 views

Hide Cash On Delivery payment method for backordered cart items in Woocommerce [closed]

In Woocommerce I would like to hide Cash on Delivery payment method if any cart item is backordered, meaning if the customer add any items to cart which are allowed for backorders but have not enough ...
1
vote
1answer
30 views

Remove specific cart item based on minimal subtotal in Woocommerce cart & checkout

In Woocommerce, I am trying to auto remove a gift product from cart if cart item is less than 300,000 dongs.Here is my code:add_action( 'template_redirect', 'remove_product_from_cart' );function ...
1
vote
1answer
38 views

Custom “Terms and Conditions” acceptance checkbox in Cart page Woocommerce

Works on small home project, and want to add checkmark option bellow "Proceed to Checkout" button into Cart page into my Woocommerce site. I found this function, that is add that option:...
1
vote
1answer
53 views

Conditional function that check if products are already in cart in Woocommerce 3

Hi solution provided here WooCommerce - Check if item's are already in cart working perfect. This is the function code:function woo_in_cart($arr_product_id) {global $woocommerce;$...
0
votes
1answer
62 views

Trying to use isset to set value but still get error

I am very new to php, and trying to create a cart page.Iv got the product Id, Option and Price being sent using the $_POST array. I want the $ino to hold the value for Id- which i does.I'm ...
1
vote
0answers
17 views

Woocommerce subscription WC()->cart->add_to_cart monthly is not working

We are selecting the number of products to insert in cart. We are using woocommerce subscription plugin for variation on yearly and monthly basis.if We are selecting 5 products to insert in cart we ...
1
vote
1answer
58 views

Woocomerce Remove a specific cart items when adding to cart another specific items

Provided solution here Remove a specific cart item when adding to cart a specific product in Woocommerce works perfect for one product id. Is any way to do this for multiple id's?
1
vote
2answers
35 views

Live update product category cart item count without reloading in Woocommerce

I created a shortcode that counts the quantity of products belonging to the '72' product category, that are added to the cart.I am using the custom conditional function has_product_category() from ...
0
votes
2answers
43 views

Adding Cart Items to the Database and retrieving

I have three tables in mySQL namely user, restaurants, cartlist.here user table is for saving the user details.restaurant table is for saving the meal details, price and quantity.cartlist is to ...
0
votes
0answers
20 views

Adding hidden field in Woocommerce add to cart button

Consider a url like this: myfirstsite/2018/10/09I want to get the 2018/10/09 and include it in woocommerce cart page and append the date to cart form. I want to pass this date as a customer ...
1
vote
0answers
30 views

Convert a .txt file and create an 3D associative array in php as a product list

I am currently a newbie in the php scene and have been trying to convert .txt file to a 3D Associative Array that stores a list of products that will $_POST data to a cart.php and checkout.php page. ...
1
vote
1answer
32 views

Remove conditionally “proceed to checkout” button from minicart in Woocommerce

In woocommerce I am currently seeking to add a function in my theme's functions.php file, if two conditions are met. Then, using elseif(), deploy the function if only one condition is met.The code ...
0
votes
1answer
20 views

Outputting a certain $_SESSION variable inside a for each loop

Im having an issue with outputting a certain session inside a foreach loop, a session that contains a certain string of characters:function cart(){foreach($_SESSION as $name=> $value){...
1
vote
1answer
38 views

Percentage Discount limited to a date range and Orders count in Woocommerce

I'm trying to make a function that sets a cart discount of 10% no matter what product or how many that are in the cart.This code works fine:function site_wide_shop_discount_with_custom_title( $...
1
vote
1answer
47 views

Disable checkout based on an allowed time range in Woocommerce

I need a time related checkout option (so if people order from past 23.59 to 06.00, the checkout will be canceled and they will be redirected to an other page). I know how to build the logics but dont ...
1
vote
1answer
36 views

Display custom backorder text from a custom field in Woocommerce cart items

This is related to :Replace product "on backorder" to a custom field value in WoocommerceI would like to display the _backorder_text product custom field value in cart items that are ...
0
votes
0answers
12 views

Product attribute label doesn't appear properly for every product into cart page of woocommerce

Product item description label does not look ok. Please check the picture.First one is ok, but the second one is not ok.How can i solve this problem? Please help me.......
0
votes
1answer
29 views

Coupons are automatically applied based on user_email

I searched for related documents but no longer works.(WooCommerce Student Discount)I need to create a coupon in WooCommerce that will only work if the user has an email which ends in hcmute.edu.vn....
0
votes
0answers
17 views

Woocommerce cart item data check for coupon validity

I have a plugin which dynamically creates a product (to be exact: replaces an existing product) in Woocommerce and adds it to cart after settings some options. It integrates with Woocommerce nicely, ...
1
vote
1answer
29 views

Set item quantity to multiples of “x” for products in a specific category in Woocommerce

I found online a snippet that allows you to set in the cart a minimum purchase to multiple quantities of “6”.Here it is:add_action( ‘woocommerce_check_cart_items’, ‘...
1
vote
1answer
26 views

Set cart item product generated sale price only for specific products in Woocommerce

Following Set only specific products sale price programmatically in WooCommerce 3, the related cart items price are not updated with the product's generated sale price. How can I get the generated ...
0
votes
0answers
15 views

User choose shipping method by product in WooCommerce checkout

I have an online store which was built with WooCommerce. I want to offer to the users the possibility of chose, item by item in the shopping cart, what shipping method they want, showing them in a ...
2
votes
1answer
32 views

Display variations attributes values as separate rows in Woocommerce cart / checkout

I have several variable products on our https://alcocovers.com/shop/ The issue I am facing is: upon adding to the cart, Dumpster Tarps has item data listed on cart page, but product Lugger Cover doesn'...

153050per page
angop.ao, elkhabar.com, noa.al, afghanpaper.com, bbc.com, time.com, cdc.gov, nih.gov, xnxx.com, github.com,