pll_get_post() function is not working
-
Hi,
I used the following to get the ID of the linked post:
if(function_exists('pll_get_post')){ echo pll_get_post($postID,$currentLang); }
Concrete scenario: The $postID is ’46’ (French version of the post) and $currentLang is ‘fr’. So it should return the $postID of the English version of this French post right? Which is 11026. But I am getting $postID of the same page, 46.
My objective is to get some custom field values from the English post so that users don’t need put the same information twice. This is why I need the linked post ID to fetch data. May be I’m missing something obvious. Can you help please?
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘pll_get_post() function is not working’ is closed to new replies.