CodeStyling Localization and layout

6.44K viewsWordPress
0

Hi,
How are you?
I’m looking to translate the template’s text via CodeStyling Localization and I’m getting two errors:
1. Loading Issue: Author is using load_textdomain instead of load_plugin_textdomain function. This may break behavior of WordPress, because some filters and actions won’t be executed anymore. Please contact the Author about that.
2. Error: The actual loaded translation content does not match the textdomain: anspress-question-answer
Expect, that any text you translate will not occure as long as the textdomain is mismatching!
This is a coding issue at the source files you try to translate, please contact the original Author and explain this mismatch.

Also, how can use the nice layout you have on http://anspress.io/questions/ ?

I’ll be glad to donate to this great plugin.

Thanks,
Eran

I have similar problem. Code style localization plugin shows an error:

Error: The actual loaded translation content does not match the textdomain: ap
Expect, that any text you translate will not occure as long as the textdomain is mismatching!
This is a coding issue at the source files you try to translate, please contact the original Author and explain this mismatch.

I checked – I changed some translations in ap-ru_RU.po but it does not change translation in my interface.

In code you use .__(‘ans’, ‘ap’) but CodeStyleLocalization says that in .po file default text domain. Maybe something wrong with .po files? I do not know yet where .po file keeps textdomains list and how to see it and change.

I will update it to load_plugin_textdomain

1

#1 No you don’t need anything to change. All should work fine, use poedit.net to edit main ap.pot file. And if you have enabled your language then your new .pot file will be loaded. If not then feel free to ping me anytime.

#2 Here is donation link Donate

#3 you are most welcome and that would be awesome.
#4 Yes AnsPress default theme is not that cool right now but I assure you we will make it better once we get done with user profile and levels.

#5 Yes of course, but after saving please update AnsPress option once (in case you get 404 error). But Do not change the Base page title from ANSPRESS_TITLE to anything else, but you can rename slug.

Thanks

This may sounds silly but I can’t find the theme’s folder under the Plugins folder, is that reasonable? where can I find the ap.pot file?

for language = anspress-questions-answer/languages/ap.pot
theme = anspress-questions-answer/theme/default/
You can override theme file by simply creating a new folder called anspress in your active theme and copy content from default theme.

I’m sorry, I meant I can’t find the *plugn* directory. I’m at “/wp-content/plugins” but I can’t find a folder with “anspress”. Can that be? Note that I am able to access the plugin’s files via Plugins->Editor. Isn’t it strange?

folder name is anspress-question-answer, cheers!

1

Hi,
Thanks a lot for commenting.
1. I’m not sure how to answer your question, I simply use the plugin at: http://www.code-styling.de/english/development/wordpress-plugin-codestyling-localization-en – is there any setting I need to modify in order to translate the plugin?
2. Thanks, where can I find a donation button?
3. I’m about to pay someone for an RTL conversion. Would you like me to share it with you when he’s done?
4. As for the template, you can be inspired from DW Question Answer – They have a nice layout for the questions page 🙂
5. Can I change the questions’ page permalink from “/anspress_title/” ?

Thanks again!

Eran

About #5, go to the Page edit of your base page and change the permalink to whatever you want. Then you may need to redone the menu with anspress and everything related and also maybe REsave the WP Permalinks once.

1

Welcome Eran,
#1 may be a bug, I will check it and let you know.
#2 I am not using anspress-question-answer as text domain as you can see its too long but WP have solution for it, you can set your own text domain. So I have registered ap as a text domain.
Please tell me which service or script you are using for CodeStyling ? I will check that too.

Wp3 theme is for old version and it have many bugs, I am working on a new theme which will be ready before end of this month.

Donations are always welcome. We are creating some extensions for AnsPress which will be distributed only to our donators.