woothemes

WooCommerce Variations as Radio Buttons

人盡茶涼 提交于 2020-04-29 07:38:48
问题 is it possible within WooCommerce to change the variations dropdown into radio buttons without having to work with a plugin? I would like to have the following setup on the variations section: 1 liter (10€) 2 liter (20€) 3 Liter (25€) The price at the bottom should be automatically changed when you select an option. Thank you 回答1: EDIT: added variation_check() and JS variation checking thanks to @ThomasB! EDIT2: make sure variation_check() also checks for backorder status to allow selection

WooCommerce Variations as Radio Buttons

不羁的心 提交于 2020-04-29 07:38:07
问题 is it possible within WooCommerce to change the variations dropdown into radio buttons without having to work with a plugin? I would like to have the following setup on the variations section: 1 liter (10€) 2 liter (20€) 3 Liter (25€) The price at the bottom should be automatically changed when you select an option. Thank you 回答1: EDIT: added variation_check() and JS variation checking thanks to @ThomasB! EDIT2: make sure variation_check() also checks for backorder status to allow selection

Data storing in the Database, Wordpress WooCommerce

六眼飞鱼酱① 提交于 2020-01-24 21:47:09
问题 I am currently coding the following, and don't seem to get my database to interact with woocommerce, this is a sign up/register form, so the information basically just needs to be posted to the database so its logged for when the user needs to use it? I have however managed to get it to logged everything such as password/first name etc, but nothing to do with woocommerce such as billing address, here is my code hope you can help! <div id="content"> <div class="titlebox" ><center><?php the

woocommerce display categories/subcategories/products

一笑奈何 提交于 2020-01-02 05:46:08
问题 is there any way to display the main categories with subcategories and their products in woocommerce? php or shortcode? I've tried with some conditional formatting,but nothing. 回答1: You have two default shortcodes available to display both, product categories (with a specific parent category defined, to display subcategories,) and products contained inside a specific category. To display top-level categories use the shortcode: [product_categories parent="0"] If you want to display

Sql query to download order report in woocommerce

♀尐吖头ヾ 提交于 2019-12-28 02:13:50
问题 please help to complete this. I need to download order report of woocommerce in csv format, for that i made the following query: header('Content-Type: text/csv; charset=utf-8'); header('Content-Disposition: attachment; filename=data.csv'); // create a file pointer connected to the output stream $output = fopen('php://output', 'w'); fputcsv($output, array('ID', 'Date', 'Status','Name')); $rows = mysql_query('SELECT ID,post_date,post_status,post_name FROM wp_posts WHERE post_date LIKE "%2016-03

No product data specified to create product [woocommerce_api_missing_product_data]

怎甘沉沦 提交于 2019-12-25 09:02:58
问题 I have downloaded latest repository of woocommerce php API. I have been following woocommerce REST API Docs to create a test product. I have copied the sample from their documentation but it is not working. Here is my code. API docs : http://woocommerce.github.io/woocommerce-rest-api-docs/?php#create-a-product <?php require_once("vendor/autoload.php"); use Automattic\WooCommerce\Client; $woocommerce = new Client( 'http://wocom.dev', 'ck_c62182de9983593c9da6ed5c4642ff50e79e1b4f', 'cs

J-Query tabs not working in Woocommerce

浪子不回头ぞ 提交于 2019-12-25 01:54:02
问题 I seem to be having some problems with my J-Query when using Woocommerce. I have installed Woocommerce and am using a custom theme (Foundation-master). Woocommerce works fine apart from the J-query of certain elements. For example on the checkout page the "ship to different address form" is always displayed despite whether the checkbox is ticked and when clicking on different payment options the default option is always displayed. There are no conflicts in the console. When I switch to the

Get WooCommerce products tags for array of products

徘徊边缘 提交于 2019-12-23 16:30:12
问题 Is it possible to get a list of WooCommerce product tags, but only if they are associated with an array of specific products? I have an array of product id's but can't fathom out where to start - I have looked at a lot of the get_tag functions in the Wordpress Codex documentation, but they all seem to be for individual post/pages/custom post types only and not for use in an array. 回答1: Why not iterate through the array get all the tags for list of products. Here is the Code which you can use: