arkadaşlar merhaba sitema hazır bir üyelik sistemini ekledim

herşeyi ile süper oldu bazı alanlara üye olmadan girilemiyo felan

ancak şimdi farkettim ki aynı üye adı ile yeni kayıtlar yapılabiliyor

mesela

editor kullanıcı isimli üye var
fakat tekrar editor ismi ile kayıt yapılıyor

bunu nasıl önlerim

yeni üye kayıtta bu alanlar boş bırakılırsa hata mesajı gösterilmiş ama kullanılan üye adı için hiç hata vermiyor

yardım edermisiniz lütfen







kayit.php bu şekilde

<center>
<table border="1" cellspacing="1" style="border:1.5pt solid #0000FF;" width="28%" id="AutoNumber1" height="2" fpstyle="6,011111100">
  <tr>
    <td width="100%" colspan="2" height="18" style="border-bottom:1.5pt solid black; font-weight: bold; color: white; background-color: #000000; border-left-style:none; border-right-style:none; border-top-style:none">
    <p align="center"><b><font color="#0000FF" face="Verdana">Üye Kaydı</font></b></td>
  </tr>
  <tr>
    <td width="25%" height="22" style="font-weight: bold; color: black; border-style: none; background-color: silver">Ad Soyad</td>
    <td width="75%" height="22" style="color: navy; border-style: none; background-color: silver"><form action="uyekayit.php" method="post">&nbsp;&nbsp; <input type="text" name="ad" id="ad" size="20"></td>
  </tr>
  <tr>
    <td width="25%" height="22" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    Üye Adı</td>
    <td width="75%" height="22" style="color: navy; border-style: none; background-color: silver">&nbsp; &nbsp;<input type="text" name="kullaniciadi" id="kullaniciadi" size="20"></td>
  </tr>
  <tr>
    <td width="50%" height="1" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    <p align="left">Şifre</td>
    <td width="50%" height="1" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    &nbsp;&nbsp; <input type="password" name="sifre" id="sifre" size="20"></td>
  </tr>
  <tr>
    <td width="50%" height="0" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    E-Posta</td>
    <td width="50%" height="0" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    &nbsp;&nbsp; <input type="text" name="posta" id="posta" size="20"></td>
  </tr>
  <tr>
    <td width="50%" height="0" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    Kısaca kendinizi tanıtın</td>
    <td width="50%" height="0" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    &nbsp;<p>
      <textarea rows="7" name="gorus" cols="20"></textarea></p>
    </td>
  </tr>
  <tr>
    <td width="100%" colspan="2" height="0" style="font-weight: bold; color: black; border-style: none; background-color: silver">
    <p align="center"><input type="submit" value="Gönder" name="B1"></form></td>
  </tr>
</table>
</center>


ve

uyekayit.php aşağıdaki gibidir
<?php

$ad = $_POST['ad'];
$kullaniciadi = $_POST['kullaniciadi'];
$sifre = $_POST['sifre'];
$posta = $_POST['posta'];

if(empty($ad)){
echo("<center><b>Adınızı Yazmadınız. Lütfen Geri Dönüp Doldurunuz.</b></center>");
}elseif(empty($kullaniciadi)){
echo("<center><b>Kullanıcı Adınızı Yazmadınız. Lütfen Geri Dönüp Doldurunuz.</b></center>");
}elseif(empty($sifre)){
echo("<center><b>Şifrenizi Yazmadınız. Lütfen Geri Dönüp Doldurunuz.</b></center>");
}elseif(empty($posta)){
echo("<center><b>E-Postanızı Yazmadınız. Lütfen Geri Dönüp Doldurunuz.</b></center>");
}else{
include("ayar.php");
$sql = "insert into uye (ad, kullaniciadi, sifre, email, gorus)
values ('$ad', '$kullaniciadi', '$sifre', '$posta', '$gorus')";
$kayit = mysql_query($sql);
}
if (isset ($kayit)){
echo "<center>Üye Kaydınız Başarı ile Yapılmıştır<br><a style='color: red'><b><u>Şimdi giriş yaparak Program ekleyebilirsiniz</u></b></a></center>

<center>
<form action='uyegiris.php' method='post'>
<table border='1' cellspacing='1' style='border:1.5pt solid #0000FF; ' width='28%' id='AutoNumber1' height='2' fpstyle='6,011111100'>
  <tr>
    <td width='100%' colspan='2' height='18' style='border-bottom:1.5pt solid black; font-weight: bold; color: white; background-color: #000000; border-left-style:none; border-right-style:none; border-top-style:none'>
    <p align='center'><b><font color='#0000FF' face='Verdana'>Üye Girişi</font></b></td>
  </tr>
  <tr>
    <td width='25%' height='22' style='font-weight: bold; color: black; border-style: none; background-color: silver'>Üye Adı</td>
    <td width='75%' height='22' style='color: navy; border-style: none; background-color: silver'>&nbsp;&nbsp; <input type='text' name='kullaniciadi' size='20'></td>
  </tr>
  <tr>
    <td width='25%' height='22' style='font-weight: bold; color: black; border-style: none; background-color: silver'>Şifre</td>
    <td width='75%' height='22' style='color: navy; border-style: none; background-color: silver'>&nbsp;&nbsp; <input type='password' name='sifre' size='20'></td>
  </tr>
  <tr>
    <td width='100%' colspan='2' height='1' style='font-weight: bold; color: black; border-style: none; background-color: silver'>
    <p align='center'><input type='submit' value='Gönder'></td>
  </tr>
</table>
</form>
</center>


";


}
else {
echo "Kayıt Başarısız";
}
?>