Tagged: credit card, Required, woocommerce
- This topic has 7 replies, 5 voices, and was last updated 5 years, 7 months ago by
Jason.
-
AuthorPosts
-
-
September 15, 2014 at 2:31 pm #2437
mattyd247MemberIs it possible to add additional meta fields to woocommerce products using Piklist?
Can it simply tap into the ‘product’ post type?
-
September 15, 2014 at 3:41 pm #2438
MarcusMemberThis would be a great test case.
Why don’t you try it?All you need to do is set the type to product or whatever is your default woocommerce product cpt type, and tell us how it goes. 🙂
Marcus
-
September 15, 2014 at 7:08 pm #2439
SteveKeymaster@mattyd247– You can add a metabox and fields using Piklist for ANY Post Type… including those registered by other plugins like Woocommerce.
-
September 16, 2014 at 2:33 pm #2443
JasonKeymasterYou sure can! I’ve done it a couple times now. You can also add additional settings pages if you’d like. 🙂
-
September 16, 2014 at 8:58 pm #2444
MarcusMemberHey Jason. Thats awesome.
I always wondered how the two would play with each other, but like so many things, it works right out of the box.
Can I ask, did Woocommerce require anything to be added to the meta_keys, like prepending ‘wc_’ to everything?
Thanks Jason.
Marcus
-
September 17, 2014 at 9:43 am #2445
JasonKeymasterHi Marcus!
WooCommerce works from a template system. Within the plugin there are templates in the templates/ directory. Simply copy the contents to your theme as /theme-name/woocommerce/. From that point on, it will retrieve your templates rather than what’s in the plugin.
From there, add the extra settings as you would any other menu and meta-boxes as you would any other post type. You then go through the somewhat tedious process of modifying the templates to reflect what you want. While doing this, just use the get_post_meta and get_option functions to retrieve the meta as you would any other time.
As a side note, the WooCommerce product has a “custom fields” meta-box, but it’s very simple. It’s not a bad idea to remove this via remove_meta_box and adding your own (better) meta-boxes. There’s nothing fancy to this meta-box, as it simply stores the key as-is in the database (no wc_ prefix or anything).
Hope this helps!
-
June 29, 2016 at 10:24 am #6843
tomthomsenMemberI recently updated Piklist and since doing so none of the credit card information is being recognized at checkout. Is this a known issue and does anyone know the fix?
-
June 29, 2016 at 2:45 pm #6854
JasonKeymasterHi @tomthomsen!
Can you please provide some more information? Have you tried disabling Piklist and it works? Are you getting an error? I use Piklist on woocommerce sites regularly without issue.
-
-
AuthorPosts
- You must be logged in to reply to this topic.