You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an ACF Field groups named "Options" that I have in 2 languages (FR / EN)
Each of them is exposed to GraphQL with Field Name = "options" and show if Options Page = Site settings
I am able to contribute it when I switch my language in my top bar without any problem.
I checked my database, and I see my fields with option_name :
options_fr_FR_banner_title (and field reference in _options_fr_FR_banner_title)
options_en_GB_banner_title (same)
So it seems that at this point, everything seems to work as expected.
But when I try to build my GraphQL request, I am able to see the language variable, the FR version (which is the default one) is returning the value correctly, but my EN version is always returning null. I tried to debug, but didn't find anything relevant yet.
I only saw this which seems weird (when using FR I do not see frFR concatened) :
SELECT option_value FROM panzani_options WHERE option_name = '_optionsenGB_cookies_banner_title' LIMIT 1
I found a workaround but it is not what I want in my front, if I change for my Field groups EN the graphql name from "options" to "options_en", I am able to retrieve the correct value. But it means that I have two different GraphQL fields for the same purpose.
Thanks in advance if someone has some tips :)
The text was updated successfully, but these errors were encountered:
Hello,
I need help because I'm probably missing something, but I'm unable to get a proper reponse to retrieve multilingual Options pages correctly.
Context
Headless Wordpress with NuxtJS front-office.
I have :
I create an Option pages like this:
I have an ACF Field groups named "Options" that I have in 2 languages (FR / EN)
Each of them is exposed to GraphQL with Field Name = "options" and show if Options Page = Site settings
I am able to contribute it when I switch my language in my top bar without any problem.
I checked my database, and I see my fields with option_name :
So it seems that at this point, everything seems to work as expected.
But when I try to build my GraphQL request, I am able to see the language variable, the FR version (which is the default one) is returning the value correctly, but my EN version is always returning null. I tried to debug, but didn't find anything relevant yet.
I only saw this which seems weird (when using FR I do not see frFR concatened) :
SELECT option_value FROM panzani_options WHERE option_name = '_optionsenGB_cookies_banner_title' LIMIT 1
I found a workaround but it is not what I want in my front, if I change for my Field groups EN the graphql name from "options" to "options_en", I am able to retrieve the correct value. But it means that I have two different GraphQL fields for the same purpose.
Thanks in advance if someone has some tips :)
The text was updated successfully, but these errors were encountered: