• I absolutely depend on Media Tags for my student researchers to store and retrieve media on our site at sge.lclark.edu. I have seen occasional oddities, however, with this taxonomy apparently conflicting with another, and now have time to look into it: it appears that when a name is duplicated in the wp_terms table, it generates an error, resulting in a suffix attached to the slug. In our case, we use a tag for each student research project, and the exact same string in Media Tags for their media. This works fine about 95% of the time, but occasionally generates errors when I’m editing a tag or media tag. The reason seems to be that my post tags and media tags share the same ID those 95% of the time, but when their IDs are different (i.e., there are >1 instances of the same name in the wp_terms table), the error occurs.

    Would sure appreciate assistance! Thanks.

    Jim P.

    http://wordpress.org/extend/plugins/media-tags/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter doctorproctor

    (@doctorproctor)

    Okay, figured out that taxonomy terms are typically shared across taxonomies, so I edited the wp_term_taxonomy table where a media-tags taxonomy did not share the term with my post tag, and all is fixed. I’m not sure how this started, but now it’d fixed on the Media-Tags dashboard page so all is well.

    Jim P.

    Plugin Author Paul Menard

    (@pmenard)

    Jim,

    Thanks for the notes. I can’t say that I know how this became in that state on your system. The Media-Tags plugin uses the standard WordPress functions to add/edit/delete Media-Tags Taxonomy terms just like is used for post tag and categories.

    In the Media-Tag code I don’t enforce uniqueness meaning I don’t check that a new Media-Tags term is not already a category or post_tag. Internally that term and the Media-Tags Taxonomy information is handled discretely.

    I’ll try and duplicate this on my test environments.

    Best,

    P-

    Thread Starter doctorproctor

    (@doctorproctor)

    Thanks, and no worries; I also noted that other custom taxonomies (added by my theme) are a part of that same table, and all share terms, which actually has created a benefit for us as we can script a little SQL operation to automatically add these terms once our students create them as post tags!

    Cheers,

    Jim

    Plugin Author Paul Menard

    (@pmenard)

    Jim, I would recommend NOT to directly add entries to the table via SQL. For each term/taxonomy there are three table which complete the relationship. Might be better to just use the WordPress taxonomy function. Up to you.

    Thread Starter doctorproctor

    (@doctorproctor)

    Well, I’m no expert, but it appears that wp_terms is invoked to create a new term, which we’ll already have once the student enters a tag for the project; and I’d assume wp_term_relationships is meant to associate a given term with an object, which we won’t have yet for the media tag (since no media yet uploaded); maybe there are other tables you’re thinking of? Again, our scenario may be different, in that a user defines a post tag as unique to the project, then we are forced to manually define this same term in Media-Tags as well as a slideshow taxonomy used by our theme prior to the user uploading media…thus I was hoping some SQL routine would make things a bit easier!…maybe not?…

    Plugin Author Paul Menard

    (@pmenard)

    The three tables are wp_terms, wp_term_relationship and wp_term_taxonomy. Good luck. Let me know if I can help with things related to Media-Tags.

    I’ve experienced a similar issue which is how I found this page. It looks like if a tag is created in Media Tags first, the same term cannot be used as a tag for posts. If the tag is created for posts first, Media Tags will create it without appending -1 to the tag.

    I’m looking for a way to use the same tags for posts and media without having to create them in both locations.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘[Plugin: Media Tags] occasional conflict with same name for tag and media tag’ is closed to new replies.