最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

plugins - force customers to add only single item to card per purchase EDD

programmeradmin1浏览0评论
Closed. This question is off-topic. It is not currently accepting answers.

Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.

Closed 6 years ago.

Improve this question

Is there any way to force Easy Digital Downloads customers to add only single item to card per purchase? In other words, disable shopping card "completely", So that when a customer touches the download button of an item, if he returns to the download archive page, it will be deleted from his shopping cart.

Thanks!

Closed. This question is off-topic. It is not currently accepting answers.

Your question should be specific to WordPress. Generic PHP/JS/SQL/HTML/CSS questions might be better asked at Stack Overflow or another appropriate Stack Exchange network site. Third-party plugins and themes are off-topic for this site; they are better asked about at their developers' support routes.

Closed 6 years ago.

Improve this question

Is there any way to force Easy Digital Downloads customers to add only single item to card per purchase? In other words, disable shopping card "completely", So that when a customer touches the download button of an item, if he returns to the download archive page, it will be deleted from his shopping cart.

Thanks!

Share Improve this question asked Jul 12, 2018 at 15:34 morteza rajabzademorteza rajabzade 415 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 3

I searched a lot and find a way to do it.

add following to theme functions.php file:

add_filter( 'edd_pre_add_to_cart_contents', '__return_false' );

Source: https://gist.github/amdrew/2192eb02839fcdf9e3d2

Thanks!

发布评论

评论列表(0)

  1. 暂无评论