Woocommerce CVS Import with Variations? - woocommerce

A site we're building is nearly complete and the last thing to do is import all the products (no problem) and importantly, product variations... I looked through the documentation, specifically the Attributes and Product Variations sections, but am still lost on how this should be done.
From the Product Variations section of the documentation, it is my understanding that a separate CSV needs to be imported just for the variations and that I need to use meta:attribute_pa_size, meta:attribute_pa_color, and meta:attribute_pa_style for the column headers.
But then, in the Attributes section, I'm assuming of the main (non-variations) CSV, it says I need to insert these columns: attribute:attribute name, attribute:pa_size, and attribute_data:pa_size
But after playing around with these columns, I'm getting nowhere and can't for the life of me get variations to import.
I have tried manually creating a product, adding variations and getting everything working, then doing a CSV export. Upon entering a new product in exactly the same format into that same CSV and reimporting, the variations still don't show up.
Maybe it has something to do with the "Attributes" menu under "Products"? I had a play in there but am still at a loss.
I know this must be possible, and help would be very much appreciated.

Here's the method I use, with great success:
Buy Mike's CSV Import Suite plugin for Woocommerce (http://www.woothemes.com/products/product-csv-import-suite/)
Create attributes and add a product with attributes
Export CSV using plugin
Use CSV as a template, and fill out the rest of the product info with attributes (split variation with the pipe '|' symbol)
Import using plugin
That should sort out your problem

WP All Import is better for importing variable products to WooCommerce because you don't need to have the CSV in a specific format like you do with the import suite from WooThemes.
The WooThemes tool is good if you already have your products inside WooCommerce and want to export them, modify them, and re-import them.
The WP All Import plugin is good if you have an XML or CSV file and just need to get it into WooCommerce without the need to modify the file to get it in some special format.

All the suggestions of exporting and using as a template are very good. However if you requires product variations then the export does not, in my experience export what is required.
To achieve this you need a live per variation and the export does not do this.
To answer sootylad's question. you are on the right track. you do need columns:
meta:attribute_pa_colour meta:attribute_pa_sizes
in the Product Variations CSV but if you want to have different attributes for each variation you need a line in the Product Variations CSV for each difference. EG if you want a different image then you need to add the image slug the "meta:attribute_pa_colour" column.
BE VERY CAREFUL - IT IS CASE SENSITIVE.
Pink is not tha same as pink.
I spent weeks on this. It was driving me round the twist.

Related

How to use URLs extracted from a website as data source for another table in Power BI

I have a situation where I need to extract tables from 13 different links, which have the same structure, and then append them into only one table with all the data. This way, at first I extracted the links from a home page by copying the link from the respective hyperlink, and then import the data through the Web connector on Power BI. However, 3 months later, I realized that those links changed every quarter but the link from the homepage where they are listed remain the same.
This way, I did some research and I found out this video on YouTube (https://www.youtube.com/watch?v=oxglJL0VWOI), which explained how I can scrape the links from a website, by building a table with the header of the link as a column and the respective link as another column. This way, I can have the links automatically updated, whenever I refresh the data.
The thing is that I am having issues to figure out how can I use this links to extract the data automatically without having to copy them one by one and then import the data using the Power BI Web connector (Web.BrowserContents). Does anyone can give me a hint of how can I implement this?
Thanks in advance!

Can I update variable products in Woocommerce using the import feature?

I'm trying to update many products at once in my Woocommerce. I thought that exporting everything, changing prices in Excel and importing back in with the update option checked would work.
It does... but only for simple products, variable products aren't updated and their stock and price stay the same.
I can't figure out if I'm doing something wrong or not or if this is not supported (although this seems like such a basic feature).
Ok, after some fiddling, I've figured it out.
For some reason, if Simple and Variable products are exported and imported in the same file, variations don't update.
So, to successfully update variable products and their variations we have to export Simple and Variable products separately.

How to add a membership cards to my website that can member downloaded

I have a website with Wordpress and I want to add members cards that they can fill their information and can download it from the website, but not sure how to do it I look for a plugin but I did not find.
also, I have 2 data on my website 'Event and Users' could I add them in one excel sheet or no?
I tried to look for a plugin
you need to separate your questions and add more information about your problem.
I'll try to help you:
** members cards **
You can use a form plugin to let the user fill the data (for example: name, surname, birth date, ecc..) that you need to print in the card. I suggest you to use this: https://formidableforms.com
the difficult way: you can intercept the form submission with formidable specific function "https://formidableforms.com/knowledgebase/frm_after_create_entry/" and with the collected data you can create image in the fly with php and imagemagik (or GD or other) https://www.php.net/manual/en/book.imagick.php. This part need that you have a little bit of experience in development. Check next point for a much simpler alternatives
the simple way: With formidable you can create a post (or better custom post) with the collected data without working on code:
https://formidableforms.com/knowledgebase/create-posts/ then you can redirect user to that page.
Invite the user to print that page and setup a specific css for print: https://benfrain.com/create-print-styles-using-css3-media-queries/

Stripping out fields from Variation in Woocommerce

I'm going to go ahead with what i'm suggesting here, but i thought i'd try and get someones thoughts at the same time
Cutting off the fat
I've got several products with 700+ variations. This becomes an issue with wordpress saving that product because it panics when it tries to save 8000+ fields and causes intermittent saving and ends up losing data.
However, looking at the variations in the backend, there are several fields that i'm not using in each variation:
weight
dimensions
virtual
downloadable
stock qty
sale price (and schedule)
etc.
If i remove these, thats at least 6 x 700 field = 4200 less fields that wordpress has to deal with, which would make saving an actual possibility.
I'm going to just defy the gods for this one and edit the woo commerce template directly to test it out.
I'm not 100% sure how to create a function that would remove these fields without harming woocommerce at this moment in time, if anyone know how, that'd be fantastic
I'll let you know my results.
I just dug around in the class-wc-meta-box-product-data.php file and there does not seem to be any easy way to remove built-in input fields. You would probably have to re-write the entire metabox.
What might be possible is a JS solution whereby you remove the fields you don't want. I am not sure at all, but if WooCommerce has proper isset() checks on all the variables its save routine then it shouldn't crash.
Or you could remove Woo's save routine and replace it with your own?
Woo's save action:
add_action( 'woocommerce_process_product_meta', 'WC_Meta_Box_Product_Data::save', 10, 2 );
This, like re-writing the entire metabox, puts you at risk of things breaking whenever WC is updated.
Just out of curiosity, how does one get 700+ variations?

Drupal import Tweets from Twitter as Nodes

I want to be able to import my tweets from twitter into Drupal as Nndes. I want to be able to link #names and #tags back to the correct pages. I also don't want myTweeterName to appear at the start of the tweet.
How would you go about doing this? The twitter module does not create nodes but stores data in its own table. The feed module can read in the tweets from the RSS feed as nodes, but will display my name and not link #names and #tags.
The following post by Gábor shows how he has done it but I am not sure how he has written a custom module to do this.
Any pointers would be appreciated.
Gabor is using the Feeds module along with the input filter from the twitter module.
From his post:
Tweets have certain special items like
#username references and #hashtags.
These should be linked to their
respective twitter.com pages, and
twitter module has input filters for
these which I could use to build up an
input format. (Given my use case, I
had no use for the rest of the twitter
module, so I took the format code into
my site-specific module, and do not
actually use twitter.module.) The
twitter feed also includes my username
at the beginning, which my site
readers will either know or do not
care about, so I also wrote a quick
filter which will transform my
username to a "from twitter" link at
the end of the node body.
You'll need to start importing your tweets using the feeds module. Then you'll need to add the input formats from the Twitter module to your default import (probably "Filtered HTML").
This is not possible any more, as Twitter does not export the user timeline as an RSS feed

Resources