word45press
Forum Replies Created
-
Forum: Plugins
In reply to: [WC Fields Factory] Include id in $attrs.It can be the same value as name
Forum: Plugins
In reply to: [WC Fields Factory] cloned wcff_builder.phpgood morning sark
The hook has been resolved, but with the clone settings it doesn’t show up. Please see the image.
Is there a problem somewhere?function my_func($attrs, $_meta, $_ptype, $_index) { $ks_valle = ‘test’; $attrs = ‘ name=”‘. esc_attr($_meta[“name”] . $_index) .'” data-fkey=”‘. $_meta[“key”] .'” ‘. $placeholder .’ data-mandatory=”‘ . $_meta[“required”] . ‘” ‘. $_readonly .’ data-field-type=”‘. $_meta[“type”] .'” autocomplete=”off” readonly value=”‘.$ks_valle.'” ‘; return $attrs; } add_filter(‘wccpf_before_preparing_common_attrs’, ‘my_func’, 10, 4);https://www.keizu-studio.com/wp-content/uploads/2022/09/ss-scaled.jpg
Forum: Plugins
In reply to: [WC Fields Factory] cloned wcff_builder.phpfunction my_func($attrs, $_meta, $_ptype, $_index)
{
$ks_valle = ‘test’;
$attrs = ‘ name=”‘. esc_attr($_meta[“name”] . $_index) .'” data-fkey=”‘. $_meta[“key”] .'” ‘. $placeholder .’ data-mandatory=”‘ . $_meta[“required”] . ‘” ‘. $_readonly .’ data-field-type=”‘. $_meta[“type”] .'” autocomplete=”off” readonly value=”‘.$ks_valle.'” ‘;return $attrs;
}
add_filter(‘wccpf_before_preparing_common_attrs’, ‘my_func’, 10, 4);Forum: Plugins
In reply to: [WC Fields Factory] About wcff_builder.phpGood morning Sark.
Thank you very muchI no longer get an unfilled alert when I press the add to cart button. It went well.
But when I increase the quantity, it disappears after cloning. The second and subsequent items are not displayed. Looking at the html source, it is value=”aaaaa”. for some reason it is not displayed.
https://www.keizu-studio.com/wp-content/uploads/2022/09/2022-09-15-01.jpg
Forum: Plugins
In reply to: [WC Fields Factory] About wcff_builder.phpGood morning Sark.
still in development. We are developing locally by flywheel. I can view it with a live link, but I would like to send the username and password to Mr. Sark’s personal email address.Forum: Plugins
In reply to: [WC Fields Factory] About wcff_builder.phpI’m sorry, and at the time of cloning.?, it was displayed at first, but when I increased the quantity and cloned, it was not displayed.
What is the problem?Forum: Plugins
In reply to: [WC Fields Factory] About wcff_builder.phpexcuse me. I thought it worked, but it didn’t. The display is properly done, but when I press the add to cart button, an unfilled alert appears and I can not move to the cart screen.Set Required to No to proceed to the next step.What’s wrong?
function wccpf_before_preparing_common_attrs_my_func($attrs, $_meta, $_ptype) { $search_word = $_SESSION['code']; $ks_valle = ''; if (($handle = fopen('wp-content/themes/lightning_child/con_info01.csv', 'r')) !== false) { while (($data01 = fgetcsv($handle, 1000, ',')) !== false) { $date = new DateTime(); $date->setTimeZone(new DateTimeZone('Asia/Tokyo')); $todaytime = $date->format('Y-m-d G:i'); $eventtime = $data01[6]; if ($data01[0] == $search_word) { if (strtotime($todaytime) > strtotime($eventtime)) { $ks_valle = ''; } else { if (esc_attr($_meta['name']. $_index == 'wccpf_fie_mosyumei'. $_index)) { $ks_valle = $data01[5].' 様'; } if (esc_attr($_meta['name']. $_index == 'wccpf_fie_kojinmei'. $_index)) { $ks_valle = $data01[1].' 様'; } if (esc_attr($_meta['name']. $_index == 'wccpf_fie_sikijyou'. $_index)) { $ks_valle = $data01[9]; } if (esc_attr($_meta['name']. $_index == 'wccpf_fie_funeral_code'. $_index)) { $ks_valle = $data01[0]; } } } } fclose($handle); } $attrs = 'readonly value="'.$ks_valle.'" '.'name="'. esc_attr($_meta["name"] . $_index) .'" data-fkey="'. $_meta["key"] .'" '. $placeholder .' data-mandatory="' . $_meta["required"] . '" '. $_readonly .' data-field-type="'. $_meta["type"] .'" autocomplete="off" '; return $attrs; } add_filter( 'wccpf_before_preparing_common_attrs','wccpf_before_preparing_common_attrs_my_func',10,3 );Forum: Plugins
In reply to: [WC Fields Factory] About wcff_builder.phpIt worked fine. Now you can easily make future updates. Thank you.
By the way, do you have any plans to send gifts to multiple destinations in the future?
The function of Cloning.? is very helpful. It would be helpful if there are multiple shipping addresses. Thank you very much.
Forum: Plugins
In reply to: [WC Fields Factory] About wcff_builder.phpgood morning. Thank you for your response.
Added the following to updateif (has_filter(‘wccpf_before_preparing_common_attrs’)) {
$attrs = apply_filters(‘wccpf_before_preparing_common_attrs’, $attrs, $_meta, $_ptype);
}It worked fine. Now you can easily make future updates. Thank you.
Forum: Plugins
In reply to: [WC Fields Factory] Built on the Japanese sitThank you. confirmed.Thank you very much.
Forum: Plugins
In reply to: [WC Fields Factory] Built on the Japanese sitThank you. confirmed.
Forum: Plugins
In reply to: [WC Fields Factory] Built on the Japanese sitgood evening. Thank you very much. Looking forward to your update.
Forum: Plugins
In reply to: [WC Fields Factory] Built on the Japanese sitHello. thank you for your reply. The site has not yet been published. I’ll post an image instead.
https://www.keizu-studio.com/wp-content/uploads/2022/09/ss001.jpgIt seems that the price tag selector is rewritten as default.
Since it is Japanese, the decimal point is not necessary.
woocommerce settings are as follows.
https://www.keizu-studio.com/wp-content/uploads/2022/09/ss003.png
please fix it