Woocommerce 删除国家/地区字段

Woocommerce 删除国家/地区字段,woocommerce,Woocommerce,可以从checkoput页面删除country字段并添加city下拉选择字段 我正在使用WC City Select插件,但它不起作用 我应该怎么做?删除文件pluginwoocommerce\includes\wc template functions.php中的一些内容 1836至1843号线附近 $field = '<select name="' . esc_attr( $key ) . '" id="' . esc_attr( $args['id'] ) . '" ' . $arg

可以从checkoput页面删除country字段并添加city下拉选择字段

我正在使用WC City Select插件,但它不起作用


我应该怎么做?

删除文件plugin
woocommerce\includes\wc template functions.php中的一些内容

1836至1843号线附近

$field = '<select name="' . esc_attr( $key ) . '" id="' . esc_attr( $args['id'] ) . '" ' . $args['autocomplete'] . ' class="country_to_state country_select ' . esc_attr( implode( ' ', $args['input_class'] ) ) .'" ' . implode( ' ', $custom_attributes ) . '>'
                        . '<option value="">'.__( 'Select a country&hellip;', 'woocommerce' ) .'</option>';
foreach ( $countries as $ckey => $cvalue ) {
                    $field .= '<option value="' . esc_attr( $ckey ) . '" '. selected( $value, $ckey, false ) . '>'. __( $cvalue, 'woocommerce' ) .'</option>';
                }
$field=''
. ''.__(“选择一个国家/地区”和“woocommerce”);
foreach(国家为$ckey=>$C价值){
$field.='''.''.'($cvalue,'woocommerce');
}
删除
国家/地区的代码

删除图片中的此代码

感谢您的帮助。

解决方案:第二个解决方案: