Saravana Kumar K
Forum Replies Created
-
Forum: Plugins
In reply to: [WC Fields Factory] Please choose product options error@jason thanks for this info.
Forum: Plugins
In reply to: [WC Fields Factory] Product price chanching not workingEach custom field’s key should be prefixed with
wccpf_, so your code should be like the following.function calculate_cart_total ( $cart_object ) { foreach ( $cart_object->cart_contents as $key => $value ) { /* You can access */ /* Check for the value (or it Could be any condition logic) */ if ( isset ( $value ["wccpf_nome_r1500"] ) && ( $value [ "wccpf_nome_r1500"] != "" ) ) { // Change the price $OrgPrice = floatval ( $value ['data']->price ); $Value['data']->price = $orgPrice * intval ( $value[ "wccpf_nome_r1500"] ); } } } add_action ( 'woocommerce_before_calculate_totals', 'calculate_cart_total', 99 );Actually it wasn’t mentioned in that blog too, updated now.
Forum: Plugins
In reply to: [WC Fields Factory] Fields don't work on mobileMore than 8 fields not at all a problem, I have tested with 15 ( mostly ) fields without any problem.
Is there any chance to view
error.log, some exception or warning messages could point us to right direction.or it could be a plugin conflicts.
to find out1. Deactivate your current theme & switch to twentytwelve theme or any of other WordPress default theme, and check whether it’s working. if it does then the issue is with your theme being used.
2. If it doesn’t work even after switching to WordPress default theme, then deactivate all plugins except
Woocommerce & WC Fields Factory and check again.Let me know
Forum: Plugins
In reply to: [WC Fields Factory] Fields don't work on mobileHi could you turn off the
Fields Cloningoption fromwp-admin/Fields Factory/Settings, and try again.Forum: Plugins
In reply to: [WC Fields Factory] Problem with variable productsHi, thanks for raising this, I got the issues. the fix simple but I cannot release it now as I am working on some pending features. So I will tell you where to edit, please update it by yourself.
Open
plugins/wc-fields-factory/classes/wcff-admin-form.phpfunction inject_wccaf_on_product_variable_section( $loop, $variation_data, $variation )LN : 170put
global $post;at the beginning of that function.function save_wccaf_product_variable_fields( $variant_id, $i )LN : 297replace that whole function with the below
function save_wccaf_product_variable_fields( $variant_id, $i ) { global $post; $parent_post_id = -1; if( !$post ) { $parent_post_id = wp_get_post_parent_id( $variant_id ); } else { $parent_post_id = $post->ID; } $this->location = "woocommerce_product_after_variable_attributes"; $all_fields = apply_filters( 'wcff/load/all_fields', $parent_post_id, 'wccaf', $this->location ); if( count( $all_fields ) > 0 ) { foreach ( $all_fields as $fields ) { if( count( $fields ) > 0 ) { foreach ( $fields as $key => $field ) { if( isset( $_REQUEST[ $field["name"] ][$i] ) ) { update_post_meta( $variant_id, "wccaf_". $field["name"], $_REQUEST[ $field["name"] ][$i] ); } } } } } }I will release the fix with my next release.
Forum: Plugins
In reply to: [WC Fields Factory] Demo?Thanks,
It’s getting ready, I will publish it soon.
Forum: Plugins
In reply to: [WC Fields Factory] Undefined offsetThanks for reporting, I will check. in the mean time, make sure there is know empty line before or after on the Options field of the Radio button meta field.
Forum: Plugins
In reply to: [WC Fields Factory] Admin field not showing on Cart or checkoutHi make sure you have turned on the following settings
Display on Cart & Checkout from
wp-admin/Fields Factory/Settings( This one is the global option applicable for all fields. ex, Product, Admin, Repeater … )and The following option has to be set for each admin fields you have created.
1. Show on Product Page this option has to be turned on to show the fields on the product page ( I think you have done this ).
2. Show on Cart & Checkout this option has to be turned on to show on cart & checkout page.
3. Order Item Meta this option has to be turned on to add this fields as order meta.
Please refer this article for more details.
Re-Arrange : Thats easy you can just drag and drop to rearrange fields on the
Fields Post EditingScreen and then hit Update button finally.File Location : all files will be uploaded on
wp-content/uploads/directory at the time of ad to cart actionif you want the file location from cart item ( before you place the order )
foreach ( WC()->cart->get_cart() as $cart_item_key => $cart_item ) { // check for your field ( fiel field ) if( isset( $cart_item["wccpf_your_field_name"] ) ) { $fobj = json_decode( $values[ 'wccpf_your_field_name' ], true ); //$fobj will be having url property $furl = $fobj["url"]; } }remember Your custom field’s key on
$cart_itemobject containswccpf_as prefix along with your custom field’sName( not label )if you want the file location from order item meta ( after you place the order )
$order = new WC_Order( $your_order_id ); foreach ( $order->get_items() as $item_id => $item ) { $furl = wc_get_order_item_meta( $item_id, "Your Field Label" ); }here the key is just your Field’s Label ( not the
namenor withwccpf_prefix )Hope it helps
Forum: Plugins
In reply to: [WC Fields Factory] Upload file not success – This field can't be EmptyFor all who facing this issue
from V1.2.9, we are using Fileinfo module to validate file uploads ( using their mime types )
PHP 5.3.0 and later have Fileinfo built in, but on Windows you must enable it manually in your php.ini
for windows this would help
Forum: Plugins
In reply to: [WC Fields Factory] Not able to add fieldsHi, do you see any script error on your browser’s developer console while trying to add the field.?
( either Chrome or FF press
Ctrl + Shift + iand go to Console tab )Forum: Plugins
In reply to: [WC Fields Factory] Text Areas do not workHi, it looks like it’s working, I am able to enter text in all the Textarea fields, I tested in Chrome, FF & Opera.
Forum: Plugins
In reply to: [WC Fields Factory] Text Areas do not workHi could you post your product page url here.? so that I can test it. product which has the TextArea Fields custom field.
Forum: Plugins
In reply to: [WC Fields Factory] How to edit a 'Text Area ' in Cart & Checkout PageHi, with current version you cannot, this feature is under development, will let you know once it is ready.
Forum: Plugins
In reply to: [WC Fields Factory] Custom Fields Data ImportSorry for the late response.
It depends on what exporter plugin you are using. but most of the plugin gives you the option to include your custom order line item meta along with the exported values.
Some plugins allows you to specify the order line meta keys, whichever you wanted to included on the exported items.
Note : Currently we are developing an Order Exporter plugin, which will be compatible with WC Fields Factory. that will be released within a week ( hopefully )