WordPress Multilingual (WPML) is a commercial plugin that adds various multilingual capabilities to WordPress.
Questions tagged [wpml]
414 questions
1
vote
1 answer
Advanced Custom Fields on WPML translations not saving
On a page/post I can copy the Advanced Custom Fields with content to the translated page but when I edit the translated page it always gets overwritten by the Advanced Custom Fields content from the default language page.
Trying to achieve:
I need…

Timotheus0106
- 1,536
- 3
- 18
- 28
1
vote
1 answer
How to translate hardcoded strings in theme's functions.php with wpml string translation?
I added a login/register and a logout menu item to my navigation. Therefore I used following code in my theme's functions.php script:
add_filter( 'wp_nav_menu_items', 'add_loginout_link', 10, 2 );
function add_loginout_link( $items, $args ) {
if…

user2718671
- 2,866
- 9
- 49
- 86
1
vote
3 answers
WPML - How navigate throught untranslated content, keeping current language value
I have a bilingual (english/french) website.
I have custom post type and custom taxonomy with the value 'do nothing' in their translation option, this is a decision made to keep this content untranslated and I want to keep it that way.
I was…

Richer St-Amand
- 96
- 1
- 7
1
vote
1 answer
Wordpress get_terms including translations
Im trying to delete all custom taxonomy objects including translations made with WPML.
$terms = get_terms('product-category');
foreach ($terms as $term) {
wp_delete_term($term->term_id, 'product-category');
}
What this does, is delete all main…

ShintoTuna
- 3,677
- 8
- 29
- 36
1
vote
1 answer
Wordpress - translate widgets (widget areas) using WPML
How to translate widgets using WPML?
Let's say I have text widget in footer that I want to have in 2 languages. Is there a human way to make it happen with WPML?
Widget Logic doesn't seem to be an answer because it lacks usability. Even I (as a…

Allan Tatter
- 1,068
- 1
- 10
- 15
1
vote
1 answer
Same name category in different languages? WPML adds `@`
I use WPML to translate my WordPress theme.
Two categories have the same name in Italian and English.
So, WPML(WordPress) adds @ and the language code after the name of the second language's category.
This because WordPress doesn't want that there's…

unemme
- 11
- 3
1
vote
1 answer
wp_get_attachment_image_src no returning resizes url
I'm having a problem with the wp_get_attachment_image_src. It's not returning the url I need for the image size for my custom sizes (or any of the default sizes). It just returns the full size image every time.
I have even tried the array version…

Josh Pyzer
- 65
- 3
- 9
1
vote
0 answers
WPML admin-ajax.php call not localized after setting lang
Calls to __() in an AJAX function are not translated even after I set the lang parameter in the AJAX URL.
It appears that Sitepress is not detecting the lang parameter properly.
I've found a workaround, but it seems cumbersome.
global…

alexsomeoddpilot
- 200
- 1
- 12
1
vote
1 answer
Wordpress Posts not loading through AJAX using WPML
I have a news page where posts are dynamically loaded based upon which category in the menu is clicked. This is done through Javascript/AJAX. The site is multi language and I'm using WPML to switch between languages. This works absolutely fine…

user2147982
- 11
- 2
1
vote
1 answer
WPML - ICL_LANGUAGE_CODE breaks my template
Using IF conditional with WPML should be easy but for some reason my template stops working as soon as i place following code in footer.php or everywhere else

user3140179
- 11
- 1
- 2
1
vote
2 answers
Disable home_url rewrite with WPML plugin
I'm using the WPML Wordpress plugin to translate my website. My default language is French. When I'm in a translated page, the home_url() is rewrite with the current language. How can I disable this rewrite so my home_url() always redirect to the…

lefoy
- 1,158
- 2
- 13
- 25
1
vote
0 answers
woocommerce and pretty permalinks and error 404
I'm fighting with WooCommerce for weeks. I'll explain.
I'm doing a website with wordpress having WooCommerce integrated online shop. This website will also have multilingual so I have built WPML (but would not have to affect it said if anything).…

XAVIER
- 11
- 2
1
vote
0 answers
MySQL query shows no results, until I copy and paste, then it gets 1
Using WordPress with WordPress MultiLanguage. I noticed a page was 404ing, so I dumped the query that was being output, and got the following (formatted exactly like below):
SELECT newsite_posts.* FROM newsite_posts JOIN…

LOLapalooza
- 2,042
- 3
- 17
- 22
0
votes
0 answers
WPML change languages
I use WPML to create a bilingual website. The website is built with Elementor. I've translated all the pages in both English and Hong Kong Chinese. However, when I edit the Elementor content while being in the English version, the corresponding…

BAMM FIREE
- 1
- 1
0
votes
0 answers
WP Media Gallery custom filter for media translation PHP snippet
I'm trying to add a filter to the WordPress media library to differentiate between original media items and their duplicates. For some reason, the filter isn't working as expected. Specifically, when I try to filter by duplicates, it shows an empty…

user3445598
- 1
- 2