Multi Vendor Marketplace Plugin | WCFM Marketplace › Forums › WCFM – Marketplace (WooCommerce Multivendor Marketplace) › Change text – State
Tagged: state to county
- This topic has 19 replies, 4 voices, and was last updated 5 years, 1 month ago by WCFM Forum.
- AuthorPosts
- June 17, 2019 at 10:02 am #68046kaloomeeParticipant
Hi
Looking to change language file
From State to County
UK has – Country > County > City/TownThanks
Kaloomee - June 17, 2019 at 10:18 am #68048sdel_nevoParticipant
Hi Mate
you can change this with Loco translate
steve
- June 17, 2019 at 2:36 pm #68080kaloomeeParticipant
Thank you sdel_nevo
Installed loco but unable to find the correct file to edit
I have tried .po for
WCFM – WooCommerce Frontend Manager – Only has ‘English (United States)’ have made edits but no frontend update.
WCFM – WooCommerce Frontend Manager – Ultimate – No english file
WCFM – WooCommerce Multivendor Marketplace – No english fileAny further help much appreciated
Regards
Kaloomee - June 17, 2019 at 4:11 pm #68095
- June 17, 2019 at 6:09 pm #68109kaloomeeParticipant
HI Steve
Thank you for taking thime to help, Much appreciated
I have created a new .po file and edited that text
Can you tell me how to make that new language file the default langauge please
I have looked in WClovers forum, documentation and knowledgebase but unable to find instructions
Regards
Kaloomee - June 17, 2019 at 7:03 pm #68115sdel_nevoParticipant
Hi mate
This may sound odd but I’m not sure to be honest, I just created an new .po and changed the text and it worked
I’m not sure if it picks up the default site settingI’m really sorry if that’s a pretty vague answer
But I can’t remember setting it as the default languageSteve
- June 17, 2019 at 7:39 pm #68136kaloomeeParticipant
Hi Steve
Okay, Thank you for taking the time to reply, Muxh pprecited – I will have a tinker and see if I can work it out
Kaloomee - June 18, 2019 at 2:05 pm #68370WCFM ForumMember
Hi,
Which text you want to change?
Please know me that list.
Thank You
- June 18, 2019 at 3:36 pm #68409kaloomeeParticipant
Just wanted to change the text from ‘State’ to ‘County’
UK has – Country > County
Not Country > State - June 21, 2019 at 6:24 pm #68923WCFM ForumMember
HI,
Please add this code to your child theme’s functions.php –
function wcfm_marketplace_custom_address_field( $address_fields ) { if( isset( $address_fields['state'] ) ) { $address_fields['state']['label'] = 'County'; } return $address_fields; } add_filter( 'wcfm_marketplace_settings_fields_address', 'wcfm_marketplace_custom_address_field' ); add_filter( 'wcfm_membership_registration_fields_address', 'wcfm_marketplace_custom_address_field' ); add_filter( 'wcfm_wcmarketplace_settings_fields_customer_support', 'wcfm_marketplace_custom_address_field' );
Thank You
- June 23, 2019 at 4:20 pm #69177
- June 26, 2019 at 3:05 pm #69779WCFM ForumMember
Hi,
Please add this code as well –
function wcfm_custom_2406_translate_text( $translated ) { $translated = str_ireplace( 'State', 'County', $translated ); return $translated; } add_filter('gettext', 'wcfm_custom_2406_translate_text'); add_filter('ngettext', 'wcfm_custom_2406_translate_text');
Thank You
- June 27, 2019 at 12:15 pm #69998kaloomeeParticipant
Thank you – Now working
It may well have been my error
I have WP multisite and add code using the ‘snippets’ plugin
I did not have that code set to network enabled – As soon as I figured this out and set to ‘Shared on network’ then enabled on that particular site – It all worked
Adding this here in case it helps others
Thank you again for your great support, Much appreciatedKaloomee
- June 29, 2019 at 4:13 pm #70244WCFM ForumMember
Thank you for sharing the information 🙂
- September 21, 2019 at 2:23 am #82727Gary FunkParticipant
since it relates and further to this post, how do we also change the labels for
Postcode/Zip to Postal Code
also is there a way to REMOVE country completely OR make it so its not actually a drop down and just shows my country?
Thanks!
- September 22, 2019 at 2:40 pm #82920WCFM ForumMember
HI,
Use this revised function –
function wcfm_custom_2209_translate_text( $translated ) { $translated = str_ireplace( 'State', 'County', $translated ); $translated = str_ireplace( 'Postcode/Zip', 'Postal Code', $translated ); return $translated; } add_filter('gettext', 'wcfm_custom_2209_translate_text'); add_filter('ngettext', 'wcfm_custom_2209_translate_text');
also is there a way to REMOVE country completely OR make it so its not actually a drop down and just shows my country?
– Restrict countries form wp-admin -> WooCommerce -> Setting – https://ibb.co/Tkh1nhRThank You
- September 23, 2019 at 9:18 pm #83227Gary FunkParticipant
thanks, only problem is it changes all instances of the word State so
Statement became Provincement
how to solve that?
thanks
- September 23, 2019 at 9:26 pm #83228Gary FunkParticipant
also for the country I have set the country there already but it still shows as a drop down for just one country… i would like to just remove the field completely or at minimum get rid of the drop down?
thanks!
- September 23, 2019 at 9:33 pm #83229Gary FunkParticipant
also i sorted out the state issue had to put in state/county and statement no longer gets replaced.
do plugins like saywhat not work with wcfm?
thanks
John - September 26, 2019 at 4:21 pm #83787WCFM ForumMember
- AuthorPosts
- You must be logged in to reply to this topic.