Hi,
I have the version 1.2.6, and I've my po/mo files from here : http://www.ericmmartin.com/projects/smcf/
I put these files in /wp-content/plugins/simplemodal-contact-form-smcf/lang/
But nothing appear, all texts are always in english...
Have you an idea ?
Have you followed the following naming convention?
- smcf-
- ISO 639 language code (lowercase)
- an underscore
- ISO 3166-1 alpha-2 country code (uppercase)
- .mo
So for an Italian translation, the file name would be smcf-it_IT.mo
You also need to make sure to update the WPLANG variable in wp-config.php:
define ('WPLANG', 'it_IT');
Yes :
smcf-fr_FR.mo
smcf-fr_FR.po
I confirm the problem, same here with ru_RU.
Have
smcf-ru_RU.mo
smcf-ru_RU.po
define ('WPLANG', 'ru_RU');
tried both - having lang files if the root folder of plugin and in the 'lang' subfolder. None worked.
I also have the exact same problem, but with french and spanish translations..
This happend right after upgrading to latest 1.2.6 smcf version, as it worked flawlessly before upgrade.
Please let us know if this is a bug and how can we fix it?
Thanks,
Has anyone resolved this problem???
Please help us!!
nbourgeo
Member
Posted 1 year ago #
To resolve this problem, you must change line 37 of /wp-content/pluginssimplemodal-contact-form-smcf/smcf.php :
load_plugin_textdomain("smcf", false, SMCF_DIR . "/lang/");
it become :
load_plugin_textdomain('smcf', false, dirname( plugin_basename(__FILE__) ) . '/lang');
Good luck.
nbourgeo,
Thanks a lot for let us know how to fix the problem!
It works perfectly now!
Thank you.
trebol
Member
Posted 6 months ago #
I got the same problem, put the code
load_plugin_textdomain('smcf', false, dirname( plugin_basename(__FILE__) ) . '/lang');
but nothing changes. I named the translation smcf-es_ES.mo
Any solution?
nbourgeo
Member
Posted 6 months ago #
Could you confirm the value of WPLANG in wp-config.php ?
It should be es_ES
define ('WPLANG', 'es_ES');
trebol
Member
Posted 6 months ago #
yeah i got the wplang changed into es_ES. translations works perfectly, except the smcf that don load, y try changing the code you say and didnt work for me. trying deleting cookies too. strange...
nbourgeo
Member
Posted 6 months ago #
Your website is it online?
trebol
Member
Posted 6 months ago #
no. i am working in my localhost.
nbourgeo
Member
Posted 6 months ago #
Your website is it only in Spanish or multilingual?
trebol
Member
Posted 6 months ago #
i installed wordpress in english, translate it with the spanish .mo file and change the wplang, how i know if i am working in multilingual?
nbourgeo
Member
Posted 6 months ago #
If you want your website to be displayed only in Spanish, the simplest solution is to rename the file SMCF-es_ES.mo in smcf.mo
trebol
Member
Posted 6 months ago #
OMG
This solution dont works too, i deleted original smcf.mo, and rename mine into this name.
smcf still open with the english one. Odd