# Submit email to database

**URL:** <https://forum.kirupa.com/t/submit-email-to-database/161441>\
**Category:** Uncategorized\
**Created:** [September 4, 2005, 12:30am UTC](https://forum.kirupa.com/t/submit-email-to-database/161441 "2005-09-04T00:30:32Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dru\_nasty](https://avatars.discourse-cdn.com/v4/letter/d/90db22/32.png) [@dru\_nasty](https://forum.kirupa.com/u/dru_nasty)\
**Post date:** [September 4, 2005, 12:30am UTC](https://forum.kirupa.com/t/submit-email-to-database/161441/1 "2005-09-04T00:30:32Z")

</div>

i’ve got a page with a form on it (just one input field)

```php

<form method="POST" action="donotemailphp.php" target="_self">
Email Address <input type="text" name="email" size="30" />
<input type="submit" value="Submit" name="submit">
</form>

```

then here is the code on the donotemailphp.php file:

```php

<?
include_once('/usr/home/fss/websites/fivestarsports.net/inc/func.inc.php');
$db_conn = five_connect_db();
mysql_select_db('fivestar',$db_conn);

$address = ($_POST['email'];

$query = "INSERT INTO donotemail(email) VALUES ('$address')";
       
?>

```

I’m trying to get the email submitted to mySQL into a table named donotemail. When I go into phpMyAdmin to see if it was added, it seems nothing happened. (i can’t browse anything) also i don’t get any errors after submitting. How would I fix this, and also know that the email was submitted.  
I know this is very elementree, but I’m learning.

Thanks in advance.
