Title: Issue with Preventing Duplicate entries code
Last modified: August 30, 2016

---

# Issue with Preventing Duplicate entries code

 *  Resolved [asha23](https://wordpress.org/support/users/asha23/)
 * (@asha23)
 * [11 years ago](https://wordpress.org/support/topic/issue-with-preventing-duplicate-entries-code/)
 * Hi,
 * I have an issue with the supplied code to stop dupes… Maybe you can help.
 * Essentially, I have added everything correctly. I’m assuming that the $formName
   variable is the name of the contact form (In the wordpress shortcode this is 
   represented by title=””
 * Is this the correct name?
 * I have entered the email field correctly.. When I test, and submit a dupe, console
   tells me that it’s a 500 error in jquery and the loader just spins. It doesn’t
   submit.
 * I’m assuming this is an ajax issue in some way.
 * [https://wordpress.org/plugins/contact-form-7-to-database-extension/](https://wordpress.org/plugins/contact-form-7-to-database-extension/)

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

 *  Plugin Author [Michael Simpson](https://wordpress.org/support/users/msimpson/)
 * (@msimpson)
 * [11 years ago](https://wordpress.org/support/topic/issue-with-preventing-duplicate-entries-code/#post-6401472)
 * Probably not ajax. Probably PHP code has an error that flows back to the ajax
   submission call. Something is wrong in your code.
 *  Thread Starter [asha23](https://wordpress.org/support/users/asha23/)
 * (@asha23)
 * [11 years ago](https://wordpress.org/support/topic/issue-with-preventing-duplicate-entries-code/#post-6401541)
 * Thanks for replying,
 * I have simply used your code verbatim. The actual error is
 * POST ([http://localhost/xxx/](http://localhost/xxx/)) 500 (Internal Server Error)
   in jquery.min.js:4
 * So not sure what’s going on, My PHP code has no errors at all, So it’s definitely
   a jQuery issue.
 *  Thread Starter [asha23](https://wordpress.org/support/users/asha23/)
 * (@asha23)
 * [11 years ago](https://wordpress.org/support/topic/issue-with-preventing-duplicate-entries-code/#post-6401551)
 * Solved it
 * It was a path issue. I have my wordpress plugins and themes in a separate folder,
   so what was happening was ABSPATH wasn’t finding the correct directory
 * 🙂

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

The topic ‘Issue with Preventing Duplicate entries code’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/contact-form-7-to-database-extension_ffffff.
   svg)
 * [Contact Form DB](https://wordpress.org/plugins/contact-form-7-to-database-extension/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/contact-form-7-to-database-extension/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/)
 * [Active Topics](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [asha23](https://wordpress.org/support/users/asha23/)
 * Last activity: [11 years ago](https://wordpress.org/support/topic/issue-with-preventing-duplicate-entries-code/#post-6401551)
 * Status: resolved