How to save post with different languages and linked them with WPML?

Thank @Sally CJ I made the solution : main code global $sitepress_settings; //Insert post with main lang $post = $binding_main_cpt[‘post’]; $default_language = $sitepress_settings[‘default_language’]; $main_post = $post[$default_language]; $postInformation = [ ‘post_title’ => wp_strip_all_tags(trim($main_post[‘post_title’] ) ), ‘post_content’ => $main_post[‘post_content’], ‘post_type’ => $main_post_type, ‘post_status’ => ‘publish’ ]; $master_post_id = wp_insert_post($postInformation); echo sprintf( “insert post %d”, $master_post_id ); foreach($sitepress_settings[‘active_languages’] … Read more

Category applied to pages, creates multiple breadcrumb entries after a search query (On the translated site)

After some time with WPML support and with some debugging/digging in the theme’s core files, I found where the breadcrumb was created. I pointed this out in the support and to also add the taxonomy on pages also in their filtered queries. I was using default WordPress queries and I was aware that taxonomies on … Read more

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