WordPress | Sub-domain switching

You can Use qTranslate, this WordPress plugin let you have an easy to use interface for managing a fully multilingual web site. One-Click-Switching between the languages – Change the language as easy as switching Choose one of 3 Modes to make your URLs pretty and SEO-friendly. – The everywhere compatible ?lang=en, simple and beautiful /en/foo/ … Read more

Set language per post

I couldn’t find an answer so I ended up providing the solution. It wasn’t simple given that I am not an expert with wordpress nor with php but WordPress documentation is great so here is the solution: // Set the post language when loading up the page based on the store meta function ppl_set_post_language() { … Read more

Force Plugin to English Translation

What’s the plugin? Is it using custom translations in mo/po files? Is there an admin interface which allows you to set the plugin locale? There is a generic filter which you might be able to add to the plugin code to set the language which might look something like the following (obviously set the language … Read more

Disable qTranslate by post type in admin + disable per page / post ID on front-end [closed]

Following snippet will disable it for post_type post (modify array below to affect other post_types): function qtrans_disable() { global $typenow, $pagenow; if (in_array($typenow, array(‘post’)) && // post_types where qTranslate should be disabled in_array($pagenow, array(‘post-new.php’, ‘post.php’))) { remove_action(‘admin_head’, ‘qtrans_adminHeader’); remove_filter(‘admin_footer’, ‘qtrans_modifyExcerpt’); remove_filter(‘the_editor’, ‘qtrans_modifyRichEditor’); } } add_action(‘current_screen’, ‘qtrans_disable’); Similarly you can disable it for specific post IDs. … Read more

Titles in my sidebar widget appear in all languages – with qtranslate

Hi Will also try this: Add this to your functions.php function get_qTrans_TitleText($text) { $language=qtrans_getLanguage(); preg_match(‘/<!–:’.$language.’–>(.*?)<!–:–>/’, $text, $matches); return strip_tags($matches[0]); } And then: <?php echo get_qTrans_TitleText($text); ?> Have no Idea what version of qTranslate and WP you have so you may even use __() to get the correct title or _e() to echo it.

WPML: getting page title in different language

Let’s say the original language of your site is english, then when visiting a german post you would return the title of the corresponding english post like that : // Get the post ID of original post $original_ID = icl_object_id( $post->ID, ‘post’, false, ‘en’ ); // Get original post title $original_title = get_the_title( $original_ID ); … Read more