Support » Plugin: Events Manager » Front-end submission: Duplication of Location in auto-complete

  • Resolved Matt Scheidler

    (@matt6303)


    My site is using the Event Submission form, for non-logged-in visitors to submit an event (subject to admin approval.) It’s working great. But today I found that the auto-complete function in the Location Name field is returning 3 results for each existing Location. There is only one Location post in the database for each location.

    The auto-complete looks something like this:

    My Location
    ,
    My Location
    ,
    My Location
    123 N. Main St., City

    Perhaps this is a conflict with another plugin I’m using. If there’s any idea of what might be causing this so that I can attempt to resolve the conflict that would be great. Thank you!

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Support angelo_nwl

    (@angelo_nwl)

    just to narrow down the problem and help us debug the issue is it possible to try the following temporarily:

    – deactivating all other plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).
    – switching to the default theme to rule out any theme-specific problems

    Angelo,

    Thank you for the reply.

    I have created a staging site, and have deactivated all plugins except for Events Manager, and also installed and activated Twenty Seventeen theme. The problem persists.

    Here is a link to the Add Event form, with all plugins off and Twenty Seventeen theme active. Example words to enter into Location Name are “mill”, “west”, and “south”. Though if you type in “north” you will find that there is only one result and it only displays once. What might be the difference?

    Staging Site

    Thanks for your help.

    Plugin Support angelo_nwl

    (@angelo_nwl)

    just to confirm, are those duplicate location status is published in the admin events > locations ?

    Thanks for the follow-up.

    (I had to turn theme, plugins, etc. back on in my staging site for other purposes, but the behavior is the same either way.)

    Each Location is in the database exactly once in Events > Locations, but most of them show up three times (as demonstrated in the initial post above) when entering a Location in the front end.

    I’m finding that if I click the first in the list, it pulls in an incorrect Location. If I click the second in the list it works correctly. And if I click the third, which has all the details, it works correctly as expected.

    Plugin Support angelo_nwl

    (@angelo_nwl)

    sorry we are having some hardtime replicating this issue; can I know what is your current EM version?

    Angelo, thanks for the reply.

    I am running EM 5.9.5 on WP 4.9.8.

    I have once again turned off all plugins (except EM) on the staging site, and activated Twenty Seventeen default theme.

    I also deleted EM from the staging site and then reinstalled 5.9.5 and the problem persists as well.

    Thanks for your interest in my issue. Let me know what else I can do to help.

    Follow-up to previous reply…I think I may have figured out what happened.

    I am looking in PHPMyAdmin for the site. Even though each Location only shows up in the WordPress admin once, the instances where we are getting this issue, there are actually multiple records in the database as such:

    location_id = 9
    post_id = 6346
    location_slug = mylocation
    location_name = My Location
    location_address = NULL
    location_town = NULL
    (all other similar fields are also null)

    location_id = 10
    post_id = 6346
    location_slug = mylocation
    location_name = My Location
    location_address = My Address
    location_town = My Town
    (all other similar fields have the correct data)

    Since “My Location” is a filled in field in both separate location IDs, that would explain why they’re both showing up in the autocomplete.

    I also noticed that all the NULL instances happened prior to the go-live for this site. I’m wondering if perhaps I had a problem when bulk importing the calendar/location items from the old site. I don’t recall now, but maybe I ran an import that failed but some of the information made it into the database, and then ran a second import. That might explain why these locations are in the database multiple times.

    I successfully deleted all the records with NULL values, via PHPMyAdmin, and at the moment everything seems OK. For now, I’m going to consider this problem resolved, and I thank you for helping me especially since it appears this wasn’t related to your plugin at all.

    I’m very glad I found this plugin – I’m using it on another in-development site right now. The level of customization with the placeholders, etc. is light years beyond what I was getting with premium plugins I’ve used previously. Thank you!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Front-end submission: Duplication of Location in auto-complete’ is closed to new replies.