Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement quantity field for home and shop page #3

Open
bobbingwide opened this issue Sep 24, 2018 · 0 comments
Open

Implement quantity field for home and shop page #3

bobbingwide opened this issue Sep 24, 2018 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@bobbingwide
Copy link
Owner

bobbingwide commented Sep 24, 2018

We need to continue to support the ability to choose the quantity when adding to the cart from the home or shop page.

Current implementation

https://github.com/bobbingwide/woocommerce-thumbnail-input-quantities
doesn't actually work. It displays the quantity field but doesn't pass the value through.

Proposed solution

https://wordpress.org/plugins/quantity-field-on-shop-page-for-woocommerce
works. But

  • it produces Notices when WP_DEBUG true
  • it has more code than we need

So, rather than change it, we can just copy the relevant code to the child theme.

Since in the current implementation the add to cart functionality takes the user to the Shopping cart
we don't need any special AJAX logic to update the values or messages on the current page.
So all we need to do is to implement the logic for the filter 'woocommerce_loop_add_to_cart_link.

The wordpress.org plugin called quantity-field-on-shop-page-for-woocommerce

@bobbingwide bobbingwide added the enhancement New feature or request label Sep 24, 2018
@bobbingwide bobbingwide self-assigned this Sep 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant