• Cant seem to figure this out. get_the_ID for instance is always returning the ID of the last query, why? Tried wp_reset_query() but that didnt do it.

    When trying to debug the query, the actually query is returning the information I want – but I can`t get hold on the data. What am I doing wrong?

    Even when I explicit pass p => 30 as an argument for the query, get_the_ID() is returning 17, which is the ID of the old query result.

Viewing 1 replies (of 1 total)
  • Thread Starter ihjalmar

    (@ihjalmar)

    WP_Post Object is showing the correct post, but cant fetch that data using get_the_title() etc.

Viewing 1 replies (of 1 total)
  • The topic ‘get_the_ID(), get_the_title() etc. is returning results from previous query.’ is closed to new replies.