product

Magento, i need define first product image as thumbnail

微笑、不失礼 提交于 2019-12-13 04:45:16
问题 I had imported my old oscommerce site with 15000 produts for magento! But unfortably, the thumbnails are dont defined automatically http://imgur.com/cNdXd i can do maually, but 15000 produts is a larg number and i need sped a big amout of time for do it if anywone can give-me a mysql command to set the first produts image as Base Image, Small Image and Thumbnail will be awesome thanks 回答1: Try update them via api: $proxy = new SoapClient('http://magentohost/api/soap/?wsdl'); $sessionId =

How to move quantity input box on archive page?

*爱你&永不变心* 提交于 2019-12-13 03:56:49
问题 In our Woocommerce website, we are using the Quantity Field on Shop Page for WooCommerce plugin. However, we don't like the position of the quantity box and want to move it so that it is directly below the "add to basket" button on our products. This is the display that I get: Below is the code of content-product.php template file: <?php /** * The template for displaying product content within loops * * This template can be overridden by copying it to yourtheme/woocommerce/content-product.php

Xcode: Update the project products group with new product name

佐手、 提交于 2019-12-13 01:27:14
问题 In the products group in Xcode, I have the library "libMyLib-mac.a" in red, even after I build for device because I have changed the product name of the library in the targets of the project to "libMyLib.a". Now, how can I update Xcode to show the new product name? ( Note: when I change the name back with the -mac suffix, the library is built and shown as available in the products folder.) 回答1: Much easier than I expected... Right click the project file in finder, and show package contents.

Disable some states if specific products are in cart in Woocommerce

拜拜、爱过 提交于 2019-12-12 23:10:19
问题 Using woocommerce, I managed to change the states to the counties here in Ireland, including the following code in the function.php function wc_ie_counties_add_counties( $states ) { $states['IE'] = array( 'Carlow' => 'Carlow', 'Cavan' => 'Cavan', 'Clare' => 'Clare', 'Cork' => 'Cork', 'Donegal' => 'Donegal', 'Dublin' => 'Dublin', 'Galway' => 'Galway', 'Kerry' => 'Kerry', 'Kildare' => 'Kildare', 'Kilkenny' => 'Kilkenny', 'Laois' => 'Laois', 'Leitrim' => 'Leitrim', 'Limerick' => 'Limerick',

Efficient axis-wise cartesian product of multiple 2D matrices with Numpy or TensorFlow

。_饼干妹妹 提交于 2019-12-12 23:06:00
问题 So first off, I think what I'm trying to achieve is some sort of Cartesian product but elementwise, across the columns only. What I'm trying to do is, if you have multiple 2D arrays of size [ (N,D1), (N,D2), (N,D3)...(N,Dn) ] The result is thus to be a combinatorial product across axis=1 such that the final result will then be of shape (N, D) where D=D1*D2*D3*...Dn e.g. A = np.array([[1,2], [3,4]]) B = np.array([[10,20,30], [5,6,7]]) cartesian_product( [A,B], axis=1 ) >> np.array([[ 1*10, 1

WooCommerce Subscriptions - Get product of a specific subscription

ⅰ亾dé卋堺 提交于 2019-12-12 20:42:42
问题 Is there a way to get from $product from $subscription ? Thanks to this post, I know that from $subscription I can get $order : $order = $subscription->order; Is this also possible? $product = $subscription->product; Or: $product = $order->product; 回答1: It is possible to get the products from either the Subscription or the matching order, as a subscription object is an extension of the WC_Order class. $subscription_products = $subscription->get_items(); $order_products = $subscription->order-

Set a min unit displayed price for variable products in Woocommerce

送分小仙女□ 提交于 2019-12-12 19:24:50
问题 I'm building a webshop in WooCommerce for selling Medical Gloves. They are being sold by unit, by box or by palet. When you buy by box or palet, you get a lower unit price. I've been playing around for a while but I can't seem to get the configuration just how I want. Let me give an example first. Product A: Price per unit: €1,90. Price per unit when buying a box: €1,76 (120 units). Price per unit when buying a pallet: €1,63 (2880 units). What i would like is the following: - on the archive

Magento Product Collection Limit via XML

ε祈祈猫儿з 提交于 2019-12-12 18:09:34
问题 I've got a bestsellers module which I've written and it works great, however I want to be able to change the collection size it returns via the XML, rather than the php/phtml. Something like this: <block type="catalog/product_list" name="bestsellers" limit="3" template="custom/bestsellers.phtml" /> or something like: <block type="catalog/product_list" name="bestsellers" template="custom/bestsellers.phtml"> <action method="setLimit">3</action> </block> Is this possible? I'm currently changing

How to get all products from woo-commerce?

淺唱寂寞╮ 提交于 2019-12-12 17:07:50
问题 I have setup Woo-Commerce which have more than 1000 products. Using Woocommerce rest api php library I am trying to get all products. But it gives me 10 products. If I use filter[limit] it gives me around 400 products not more than this. $res = $wc_api->get_products(array( 'filter[limit]' => 400 ) ); Can anyone say me how can I get all products from woocommerce? 回答1: For the latest version of the WC API, use $products = $client->products->get( '', ['filter[limit]' => -1] ); If it's not

Prestashop: How to get accessories for product

允我心安 提交于 2019-12-12 10:08:07
问题 how can I get accessories for each product? In a loop: {foreach $products as $product} // get accessories {/foreach} 回答1: The problem is that the module HomeFeatured doesn't retrieve accessories for products so they aren't available in the template. You have the choices : edit the PHP code of the module : simple but not upgrade proof duplicate the module to myhomefeatured : easy too but less, and upgrade proof I prefer the 2nd, more future proof & you can add more and more logic after if you