Either you do a SELECT with the data the user entered.If you don't find a match the data does not exist
Or (better in my opinion) you make the column(s) UNIQUE (http://dev.mysql.com/doc/mysql/en/create-table.html) and simply try inserting.
If no error occurs everything is fine and if an error occured ([man]mysql_affected_rows[/man] or [man]mysql_error[/man]) something went wrong and almost for sure this is because the data already exists