custom taxonomy does not appear

#948501
  • Resolved hdfilmseyri
    Rank Math free

    hello, there are special taxonomies on my site. these are separated such as director, country, year of production. they all appear and work in the title and meta section, but when I try to write the year of production in the meta description in the “posts” section, this taxonomy does not come and it writes a special term.

    For example, I am throwing my code, this is used in the sense of Turkish year = “yil”

    register_taxonomy(‘yil’, ‘post’, array(‘hierarchical’ => false, ‘labels’ => array(‘name’ => _x(‘Production Year’, ‘taxonomy general name’), ‘singular_name’ => _x(‘Production Year’, ‘taxonomy singular name’), ‘search_items’ => __(‘Search Production Year’), ‘all_items’ => __(‘All years’), ‘edit_item’ => __(‘Edit Production Year’), ‘update_item’ => __(‘Update Production Year’), ‘add_new_item’ => __(‘Add new Production Year’), ‘new_item_name’ => __(‘New Production Year’), ‘menu_name’ => __(‘Production Year’),), ‘rewrite’ => array(‘slug’ => ‘yil’, ‘with_front’ => false, ‘hierarchical’ => false),));

    Here’s what I tried in the meta description:
    %customterm(yil)%
    %customterm(term_year)%

    but it’s not working. I hope you can help me.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello,

    We apologize for the issue you are facing with the custom taxonomy not appearing in the meta description. It seems that you are trying to use the %customterm(yil)% variable, which is correct for displaying a custom term in your title or description. However, if it is not working as expected, there are a few things to check:

    1. Ensure the Taxonomy is Registered Correctly: Make sure that the custom taxonomy ‘yil’ is registered properly in your theme or plugin. The code snippet you provided looks correct, but double-check that it is being executed.

    2. Check Post Type Association: Ensure that the custom taxonomy ‘yil’ is associated with the correct post type (in your case, ‘post’). If you are using a different post type for your articles, you may need to adjust the registration accordingly.

    3. Use the Correct Variable: You mentioned trying %customterm(term_year)%, but it should be %customterm(yil)% if ‘yil’ is the correct taxonomy name. Make sure there are no typos.

    4. Meta Box Settings: Verify that the Rank Math meta box is enabled for the post type where you are trying to add the meta description. You can check this in the Titles & Meta settings of Rank Math.
      Select Post Type/ Taxonomy

    5. Caching Issues: Sometimes caching plugins can cause issues with displaying updated content. Clear any caches and check again.

    If you have checked all of these and it still does not work, we recommend replying to this ticket so a human agent from the Rank Math Support team can assist you further. Thank you for raising this concern!

    Sources:
    Why Rank Math’s Meta Box is Not Showing? » Rank Math

    Hello,

    Thank you for contacting Rank Math support.

    The customterm variable shows the Custom Term Value in the snippet editor but it will add the correct term in the page source on the front end. You can check the page source or use the following tool to confirm that: https://rankmath.com/tools/meta-tag-analyzer/

    Please do not hesitate to let us know if you need our assistance with anything else.

    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.

Viewing 2 replies - 1 through 2 (of 2 total)

The ticket ‘custom taxonomy does not appear’ is closed to new replies.