If a record matches an existing record do nothing


Posted on 16th Feb 2014 07:03 pm by admin

So I don't know if I should put this here or in mysql, but what my script is for is for people to add their emails to our mailing list. Pretty simple, I got that working. But what I want it do now is that if somebody puts their email in and their email is already added to our database then it doesn't do anything. but if their email isn't in our database then it will add it.

So basically stop duplicate records. Is there any way to do this php? I'm sure there is, its just not coming to me.

No comments posted yet

Your Answer:

Login to answer
232 Like 20 Dislike
Previous forums Next forums
Other forums

Frustrated php Newbie
First off, I am pretty much a PHP nub. I can read and understand the language (most of the time) so

Mysql error message
help me find out what this error message means:

"Duplicate entry '0' for key 'PRIMARY'&q

Performance impact of cookies
Hi, I was just wondering what impact there would be in terms of performance if you where to set then

foreach help.
Hello all,

First time I'm attempting to use a foreach statement and was just wondering if my

Month String to Numeric?
Hi guys,

Given a month as a string, is there a simple way to find the numeric representation

Create multiple (n) arrays
Hi there,

I have the following need:

I have 2 arrays (coming from a databases)

Help with captcha script needed
Hello,

I am working on a script where reCAPTCHA or a similar form of CAPTCHA will be used, f

single page with referrer to show correct page
I have a simple website with a couple of different pages. I would like to be able to in a div tag w

recrawling
Can anyone suggest me how may i know a page is updated before it is being downloaded, so that i can

Code doesn't print what i wanted it too. Please help!
Hi there,

I wrote this code to mae it so that in the form before it that the user said their

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash