Simple way to get two language WP site

You can use below code for translating strings: add_filter(‘gettext’, ‘translate_text’); add_filter(‘ngettext’, ‘translate_text’); function translate_text($translated) { $translated = str_ireplace(‘Choose an option’, ‘Select’, $translated); $translated = str_ireplace(‘Original Text’, ‘Your Replacment Text’, $translated); return $translated; } But I have no idea for translating complex contents. I know you don’t want to use plugins but as my research, we … Read more

Theme check: Missing a text-domain

Let us look at the relevant line. I am reformatting it to easier understand what is going on: printf( _n(‘1 comment’, ‘%1$s comments’, get_comments_number() ), number_format_i18n( get_comments_number() ), ‘text-domain’ ); So what you are doing is calling printf with three parameters, each one now being on a separate line now as I formatted it. But … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)