PHP Form - "Email address already exists"

Hi,

I am the admin for the following page - www.########.com

When checking out on the shopping cart - http://########.com/index.php?p=billing_and_shipping_address - and you use an email that has already placed an order, it returns the following error:

Please check error(s)
Email address already exists

Does anyone know how to repair this? We have many repeat customers that are unable to order.

Thank you for your time!

Greg

Well, without any code, it is hard to tell you. But a few quesses…

If you are trying to update a record, it depends on the code you use. If the email address is a primary key, you might not be able to update it. I have had some odd things caused due to primary keys. Also, if that field is set to be unique, a similar error might be caused.

Well, you can also place some error-checking code in the update section to trap the error. You can find that all over the internet or we can post some for you.

Could you post some of the update code so we can look at it.

the error “Email address already exists” is something that is hard coded in, that is not a server error, so there is a piece of code that checks the database for the email and if it exists it serves up the error die(“Email address already exists”);

You need to find this and change a good portion of the code. I am thinking that it does the check and if everything is ok then it does an “Insert”. so you are going to have to change it to where if the email exists it will update that user.
But as the user before me has mentioned without you actually showing us the code, there is nothing more we can do to try to help!

Thank you guys for your replys!! I really appreciate the help…

I will def post the code, but I am very new to PHP, and I feel this page was poorly written…

Should I post all the code, or just his ‘email check string’?

What would the email check string look like?

Not to be mean or anything, but actually I think you should be hiring a programmer to work on that. You are not asking for simple help in solving a problem you have, you are looking for someone to code the whole thing for you for free which is totally different.

No, I understand completely…that was one of the main reasons I was asking… wasn’t sure if it was a simple fix or major problem.

If you advise I hire a programmer to diagnose then I will go that direction…

A hired programmer would be best, as the others have said. But, if you are attempting this yourself, you would need to post the email code. If this is a previously working system, you need to look at what has changed. If you look at the changelist from whoever had the ADMIN job before, you may find an update was done that might send you to the correct area of the code.

Good luck.

my money is on: a hidden login feature and defaults to registering…

Sponsor our Newsletter | Privacy Policy | Terms of Service