Hello,
Thank you for contacting us and sorry for any inconvenience that might have been caused due to that.
Could you please clarify where exactly do you want to display that information?
We ask that because if it’s in the metadata, you can use the following filter to create a custom variable that can be used there: https://rankmath.com/kb/filters-hooks-api-developer/#add-extra-variables
If you want to edit the title of the page and add that information there you can use the following filter to modify the title that appears on the frontend: https://rankmath.com/kb/filters-hooks-api-developer/#change-the-title
The default way to get the category for a post in WordPress is by using the get_the_category() function and that might be the easiest solution for this use case.
Both of these filters need to be modified as per your requirements.
Hope this helps get you closer to the final solution.
Don’t hesitate to get in touch if you have any other questions.
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.