Gravity Forms + Custom Post Types
Can i either A) remove dashes from taxonomy dropdown, or B) map text to taxonomy (3 posts)

  1. kateM82
    Posted 4 years ago #

    I have installed the custom post & taxonomy add on (it's great thanks), but one little problem.

    I want to be able to use the item selected from the drop down as an actual word in other places in the form (ie in SEO fields, and in some other custom fields). But when someone selects one of the sub-items from the taxonomy drop down, the "--" come with it.

    So i'd like to either A) be able to get rid of those dashes, or B (preferably), can someone please tell me how I can map a normal drop down field or check box to a taxonomy (including sub-menu taxonomy items), thanks.

    If that's not completely clear an example of how the taxonomy list is:




  2. bradvin
    Plugin Author

    Posted 4 years ago #

    you can remove the "--" dashes by editing the file :


    comment out line 161:

    $item->name = str_repeat('--', $level) . $item->name;

    so you end up with

    //$item->name = str_repeat('--', $level) . $item->name;

  3. bradvin
    Plugin Author

    Posted 4 years ago #

    Just want to clarify:

    are you saving the form to a post type? Because the "--" are only visual to show the hierarchy in the form. Behind the scenes, the id of the term is saved. Or if you create a post, then the post is automatically linked to the taxonomy term.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Gravity Forms + Custom Post Types
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic