<?
include("config.php");

mysql_connect(localhost,$username,$password);
@mysql_select_db($database) or die( "Nie można otworzyć bazy danych");

$message = $_POST['message'];

$query = "INSERT INTO lista (wiadomosc) VALUES ('$message')";
mysql_query($query);

mysql_close();

?>

<script>
alert('Tweet Added');
window.location.href = "index.php";
</script>
