Events Manager ESS
[resolved] Finding event category by slug is not always a good idea (3 posts)

  1. dnk6742
    Posted 1 year ago #

    I have categories named in russian and slugs are translations, not transliterations according to the rules. In the feed, only the category names are exported; so, finding the category among my categories on syndicating site will fail and new category will be created with name, matching the category that already exists.

    Solution: either start to export a slug or start picking categories by name.
    For me, adding in ESS_Import, line 339 $category_term = get_term_by( 'name', $category_name, EM_TAXONOMY_CATEGORY );
    and changing the wollowing code to $term_array = wp_insert_term( $category_name, EM_TAXONOMY_CATEGORY, array('name' => $category_name));
    solved the problem.

    I suggest to do both.


  2. essfeed
    Plugin Author

    Posted 1 year ago #

    I see your problem.., it's a sounds a good idea to do the matching with the name. I've replaced the evaluation script with 'name' instead of 'slug'.
    As it only concerns languages with special chars it shouldn't disturb other websites.

    The fix will be published in the next release.

  3. dnk6742
    Posted 1 year ago #

    It concerns all sites where slugs are customized :-) Thanks.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Events Manager ESS
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic


No tags yet.