<!-- #INCLUDE file="bag.asp" -->
<%  If  session("adminmi") = ""  Then  
response.redirect "sifre.asp"
response.redirect "../ayarlar.asp"

End If
%>	
<head>
<style type="text/css">

A {text-decoration:none;}
A:hover {color:FFFFFF;}
BODY {     
           scrollbar-3d-light-color:#F4EEE6;
           scrollbar-arrow-color:#640000;
           scrollbar-base-color:#FFE3BD;
           scrollbar-dark-shadow-color:#FE9810;
           scrollbar-face-color:#ffffff;
           scrollbar-highlight-color:#f7f7f7;
           scrollbar-shadow-color:#FFE3BD}
           
SELECT, option, textarea, input {FONT-FAMILY:verdana,arial;color:#666666; FONT-SIZE: 12px; background-color:#eeeeee  }

body, table, tr, td        {  font-family : tahoma; font-size: 8 pt  }


a:link, a:visited, a:active {text-decoration:none; color:#044B93; font-weight:plain;}

a:hover {
	text-decoration:none;
	color:#FF0000;
	font-weight: plain;
}
.stil_menu {font-family:Verdana, Arial,Helvetica;font-size: 8pt}

.bottom { vertical-align: bottom }

.top { vertical-align: top }

.poster { FONT-SIZE: 12px }
 
 </style>
		<link href="../testcases.css" rel="stylesheet" type="text/css" />

<!-- #INCLUDE file="fckeditor.asp" -->
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-9"><style type="text/css">
<!--
body,td,th {
	font-family: verdana;
	font-size: 11px;
}
a:link {
	color: #0000FF;
}
-->
</style></head>

<body topmargin="0" leftmargin="0">

<table width="100%" border="0" align="center" cellpadding="4" bordercolor="#111111" style="border-collapse: collapse">
<tr>
		<td width="20%" valign="top">
		<!--#include file="menu.asp"-->
    	</td>
		<td width="80%" valign="top" align="center">
		<%   db_veriyolu ="../" & vtyolu & "/"& vtadi &""
			 Set rs=Server.CreateObject("Adodb.Recordset")
		     
			set veri = server.createobject("adodb.connection")
			veri.open "provider=microsoft.jet.oledb.4.0;data source=" & Server.mappath(db_veriyolu & ".mdb")
		     'Set veri = Server.CreateObject("ADODB.Connection")
		     'veri.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("../65465879a23423455ads_ads/siv54854reh313.mdb") 
	%><%
   
      select case request("sayfa")
      case "yorum_sil"
veri.execute("delete from yorum where id="&request.querystring("id"))
response.redirect "kose.asp"
case "yorum_onayla"
veri.execute("update yorum set onay=1 where id="&request.querystring("id"))
response.redirect "kose.asp"
case "yorum"
kid = request.querystring("kid")
%>
		<table border="0" cellpadding="4" style="border-collapse: collapse" bordercolor="#111111" width="100%">
			<tr>
				<td width="100%"><b><font color="#CC3300">.. Onaysiz Yorumlar</font></b></td>
			</tr>
		</table><br>
<%
Set rs=Server.CreateObject("Adodb.Recordset")
              rs.cachesize = 10 
              rs.pagesize  = 10
    rs.open "select * from yorum where onay = 0 order by id desc",veri,1,3

if not rs.eof then
%>
	
  <%sayfa = Request.QueryString("sayfalar")
      If sayfa ="" Then sayfa="1"

      rs.absolutepage = sayfa

      sayfa_sayisi = rs.pagecount
      for i=1 to rs.pagesize
      If rs.eof Then exit for
	  if renk="" then
      renk=renk1 
      elseif renk=renk1 then
      renk=renk2
      elseif renk=renk2 then
      renk=renk1
      end if
      id = rs("id")
      %>

  		<table border="0" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%">
      <tr>
        <td width="313">Yazi</td>
        <td width="5">:</td>
        <td width="634"><%set haber =veri.execute("select top 1 baslik from yazi where id="&rs("hid"))
if not haber.eof then
response.write haber("baslik")
end if
haber.close : set haber = nothing%></td>
      </tr>
      <tr>
        <td width="313">Ad Soyad</td>
        <td width="5">:</td>
        <td width="634"><%=rs("isim")%></td>
      </tr>
      <tr>
        <td width="313">Mail</td>
        <td width="5">:</td>
        <td width="634"><%=rs("mail")%></td>
      </tr>
      <tr>
        <td width="313">Yorum</td>
        <td width="5">:</td>
        <td width="634"><%=rs("yorum")%></td>
      </tr>
      <tr>
        <td width="313">Tarih</td>
        <td width="5">:</td>
        <td width="634"><%=rs("tarih")%></td>
      </tr>
      <tr>
        <td width="313">IP</td>
        <td width="5">:</td>
        <td width="634"><%=rs("ip")%></td>
      </tr>
      <tr>
        <td width="313">&nbsp;</td>
        <td width="5">&nbsp;</td>
        <td width="634">
        <p align="right"><a href="?sayfa=yorum_onayla&id=<%=id%>">Onayla</a> |
        <a href="?sayfa=yorum_sil&id=<%=id%>">Sil</a></td>
      </tr>
    </table>
  <%
    rs.movenext
    Next
  %>
 
<script language="JavaScript">
function sayfasec(hangisi){
if (hangisi == 1) {
		document.kategori_sayfalari.submit();
	}
	else {
		document.kategori_sayfalari2.submit();
	}
}

                     </script>

		<br>
		<table border="0" cellpadding="3" style="border-collapse: collapse" bordercolor="#111111" width="100%">
			<tr>
				<td width="70%" bgcolor="#F5F5F5"><b><%=sayfa_sayisi%></b> Sayfada, Toplam<b> <%=rs.recordcount%></b> 
                Onaysiz Yorum </td>
				<form method="GET" action="kose.asp" name="kategori_sayfalari">
					<td width="30%" bgcolor="#F5F5F5" align="right">Sayfalar : 
					<select size="1" name="sayfalar" onChange="sayfasec(1);"><%
        
        for i=1 to sayfa_sayisi
        if i=int(sayfa) then
        sec=" selected"
        end if
        %>
				  <option value="<%=i%>"<%=sec%>><%=i%></option><%
        sec=""
        next
        %></select> </td>
					<input type="hidden" name="sayfa" value="yorum">
				</form>
			</tr>
		</table>
<%
else
response.write " Onay Bekleyen Yorum Yok"
end if
rs.close : set rs = nothing


      case "sil"
         id = request.querystring("id")
      veri.execute("delete from yazarmesaj where id="&id)
      response.redirect geri
      case "mesaj"
      yid = request.querystring("yid")
      
Set rs=Server.CreateObject("Adodb.Recordset")
              rs.cachesize = 10
              rs.pagesize  = 10
    rs.open "select * from yazarmeSaj where yid="&yid&" order by id desc",veri,1,3

if not rs.eof then
sayfa = Request.QueryString("sayfalar")
      If sayfa ="" Then sayfa="1"

      rs.absolutepage = sayfa

      sayfa_sayisi = rs.pagecount
      for i=1 to rs.pagesize
      If rs.eof Then exit for
	 
      id = rs("id")
      %>
    <table border="0" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%">
      <tr>
        <td width="33%"><b><font color="#CC3300">İsim</font></b></td>
        <td width="1%"><b><font color="#CC3300">:</font></b></td>
        <td width="66%"><%=rs("ad")%></td>
      </tr>
      <tr>
        <td width="33%"><b><font color="#CC3300">Mail</font></b></td>
        <td width="1%"><b><font color="#CC3300">:</font></b></td>
        <td width="66%"><%=rs("mail")%></td>
      </tr>
      <tr>
        <td width="33%"><b><font color="#CC3300">Konu</font></b></td>
        <td width="1%"><b><font color="#CC3300">:</font></b></td>
        <td width="66%"><%=rs("baslik")%></td>
      </tr>
      <tr>
        <td width="33%"><b><font color="#CC3300">Tarih</font></b></td>
        <td width="1%"><b><font color="#CC3300">:</font></b></td>
        <td width="66%"><%=rs("tarih")%></td>
      </tr>
      <tr>
        <td width="33%"><b><font color="#CC3300">Mesaj</font></b></td>
        <td width="1%"><b><font color="#CC3300">:</font></b></td>
        <td width="66%"><%=rs("mesaj")%></td>
      </tr>
      <tr>
        <td width="33%">&nbsp;</td>
        <td width="1%">&nbsp;</td>
        <td width="66%">
        <p align="right"><b><a href="?sayfa=sil&id=<%=id%>">[Sil]</a></b></td>
      </tr>
    </table><br><br>
     <%
    rs.movenext
    Next
  %>
 
<script language="JavaScript">
function sayfasec(hangisi){
if (hangisi == 1) {
		document.kategori_sayfalari.submit();
	}
	else {
		document.kategori_sayfalari2.submit();
	}
}

                     </script>

		<br>
		<table border="0" cellpadding="3" style="border-collapse: collapse" bordercolor="#111111" width="100%">
<tr>
				<td width="70%" bgcolor="#F5F5F5"><b><%=sayfa_sayisi%></b> Sayfada, Toplam<b> <%=rs.recordcount%></b> 
                Mesaj</td>
				<form method="GET" name="kategori_sayfalari">
					<td width="30%" bgcolor="#F5F5F5" align="right">Sayfalar : 
					<select size="1" name="sayfalar" onChange="sayfasec(1);"><%
        
        for i=1 to sayfa_sayisi
        if i=int(sayfa) then
        sec=" selected"
        end if
        %>
				  <option value="<%=i%>"<%=sec%>><%=i%></option><%
        sec=""
        next
        %></select> </td>
				    <input type="hidden" name="sayfa" value="mesaj">
				    <input type="hidden" name="yid" value="<%=yid%>">
				</form>
			</tr>
		</table>
<%
else
response.write "Henüz Bu Yazara Gelen Msj Yok"
end if

      case "g1d"
Set Upload = Server.CreateObject("Persits.Upload.1") 
Count = Upload.SaveToMemory 

       
    Set File = Upload.Files(1) 
    randomize 
    sayi = int((9999*rnd)+1) 
dosya_adi = session.sessionid &sayi&"."&file.imagetype
     id = upload.form("id") 

set yazar = veri.execute("select top 1 * from yazar where id="&id) 
resim_adi=yazar("grafik1")
yazar.close
veri.execute("update yazar set grafik1='"&dosya_adi&"' where id="&id)
 Path = server.mappath("..\kose_resim") &"\"& dosya_adi


  File.SaveAs Path 
  
  Upload.DeleteFile  server.mappath("..\kose_resim") &"/" &resim_adi 
response.redirect "kose.asp?sayfa=yazar_duzenle&id="&id
      case "grafik1"
      id = request.querystring("id")
      %>
      <table border="1" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#C0C0C0" width="100%">
        <form method="POST" enctype="multipart/form-data" action="?sayfa=g1d">
        <tr>
          <td colspan="3" bgcolor="#F5F5F5"><font color="#CC3300">Resm Yükleyin...</font></td>
        </tr>
        <tr>
          <td width="297" style="border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium">Resim Yolu</td>
          <td width="1" style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium"><div align="center">:</div></td>
          <td width="644" style="border-left-style: none; border-left-width: medium; border-bottom-style: none; border-bottom-width: medium"><input  name="g1" type="text" id="g1" style="width:180px; font-size:11px;font-weight:normal;color:#336666;text-decoration:none">
   <a onClick="yenipencere('yazarresimyukle.asp',450,350)">Bilgisayardan Yükle</a></td>
        </tr>
        <tr>
          <td width="297" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium">&nbsp;</td>
          <td width="1" style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium">&nbsp;</td>
          <td width="644" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium">
          <input type="submit" value="Degistir" name="B1"></td>
        </tr>
        <tr>
          <td colspan="3" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium"></td>
          </tr>
        <input type="hidden" name="id" value="<%=id%>">
        </form>
      </table>
      <%
        case "g2d"
Set Upload = Server.CreateObject("Persits.Upload.1") 
Count = Upload.SaveToMemory 

       
    Set File = Upload.Files(1) 
    randomize 
    sayi = int((9999*rnd)+1) 
dosya_adi = session.sessionid &sayi&"."&file.imagetype
     id = upload.form("id") 

set yazar = veri.execute("select top 1 * from yazar where id="&id) 
resim_adi=yazar("grafik2")
yazar.close
veri.execute("update yazar set grafik2='"&dosya_adi&"' where id="&id)
 Path = server.mappath("..\kose_resim") &"\"& dosya_adi


  File.SaveAs Path 
  
  Upload.DeleteFile  server.mappath("..\kose_resim") &"/" &resim_adi 
response.redirect "kose.asp?sayfa=yazar_duzenle&id="&id
      case "grafik2"
      id = request.querystring("id")
      %>
      <%

      case "yazar_guncelle"
       id = request.form("id")
  	   rs.open "select * from yazar where id="&id,veri,1,3
       rs("ad_soyad")=request.form("ad_soyad")
       rs("mail")=request.form("mail")
	   rs("kulladi")=request.form("kulladi")
       rs("sifre")=request.form("sifre")
       rs("sira")=request.form("sira")
	   if Request.form("resim")<>"" then
	    rs("grafik1") = Request.form("resim")
	   end if
       rs.update
	   response.redirect "kose.asp"
  %>
  <table border="1" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#C0C0C0" width="100%" bgcolor="#F5F5F5">
    <tr>
      <td width="100%">
      <p align="center"><font color="#CC3300"><br>
      Yazar Güncellendi<br>
      <br>
      <a href="kose.asp">Düzenleme Ekranina Dönmek için&nbsp; Tiklayin</a></font><br>
&nbsp;</td>
    </tr>
  </table>
  <%
      case "yazar_duzenle"
      id = request.querystring("id")
      set yazar = veri.execute("select * from yazar where id="&id)
     %>
     <font color="#CC3300"> </font>
       <script Language="JavaScript" Type="text/javascript"><!--
function kontrol(form)
{

  if (form.ad_soyad.value == "")
  {
    alert("Yazarın adını yazmadınız.");
    form.ad_soyad.focus();
    return (false);
  }
       

      if (form.mail.value == "")
  {
    alert("Mail adresini yazmadınız.");
    form.mail.focus();
    return (false);
  }
     
      if (form.sifre.value == "")
  {
    alert("şifre yazmadınız.");
    form.sifre.focus();
    return (false);
  }
  return (true);
}
//--></script> 
       	<table border="1" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#C0C0C0" width="100%">
<form method="POST" action="?sayfa=yazar_guncelle" onSubmit="return kontrol(this)" language="JavaScript">
				<tr>
					<td colspan="4" bgcolor="#F5F5F5">
					<font color="#CC3300">Yazar Düzenle</font></td>
		  </tr>
				<tr>
					<td width="183" style="border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium">Ad Soyad</td>
				  <td width="5" style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium">:</td>
					<td width="180" style="border-left-style: none; border-left-width: medium; border-bottom-style: none; border-bottom-width: medium">
				  <input type="text" name="ad_soyad" size="30" value="<%=yazar("ad_soyad")%>"></td>
		            <td width="564" style="border-left-style: none; border-left-width: medium; border-bottom-style: none; border-bottom-width: medium"><div align="center"><span style="border-left-color: #C0C0C0; border-left-width: 1; border-right-color: #C0C0C0; border-right-width: 1"><font color="#CC3300">Yazarın Resim</font></span></div></td>
		  </tr>
				<tr>
                  <td style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">Mail</td>
                  <td style="border-style: none; border-width: medium">:</td>
                  <td style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">
                    <input type="text" name="mail" size="30" value="<%=yazar("mail")%>"></td>
			      <td width="564" rowspan="4" valign="top" align="center"><img src="../kose_resim/<%=yazar("grafik1")%>" width="85" height="110" border="1"></td>
			  </tr>
				<tr>
					<td width="183" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">Kullanıcı Adi</td>
				  <td width="5" style="border-style: none; border-width: medium">:</td>
					<td width="180" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">
					  <p>
					    <input type="text" name="kulladi" size="20" value="<%=yazar("kulladi")%>">
					  </p>				  </td>
          </tr>
				<tr>
					<td width="183" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">Sifre</td>
				  <td width="5" style="border-style: none; border-width: medium">:</td>
					<td width="180" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">
				  <input type="text" name="sifre" size="20" value="<%=yazar("sifre")%>"></td>
          </tr>
				<tr>
					<td width="183" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style:none; border-bottom-width:medium">Sira</td>
				  <td width="5" style="border-style:none; border-width:medium; ">:</td>
					<td width="180" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style:none; border-bottom-width:medium">
				  <input type="text" name="sira" size="3" value="<%=yazar("sira")%>"></td>
          </tr>
				<tr>
					<td width="183" height="31" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium">&nbsp;</td>
				  <td width="5" style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium">&nbsp;</td>
					<td width="180" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium">
				  <input type="submit" value="Güncelle" name="B1"></td>
                  <td width="564" valign="middle" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">Resim Adı : 
                    <input  name="resim" type="text" id="resim"  value="<%=yazar("grafik1")%>" size="25">
   <a onClick="yenipencere('yazarresimyukle.asp',450,350)">Yeni Resim Yükle</a></td>
		  </tr>
			    <input type="hidden" name="id" value="<%=id%>">
			</form>
		</table>
<br>
<%
     case "sg"
     for i=1 to Request.form("id").count
    id=request.form("id")(i)
    id=replace(id,"F","")
   
    sira=request.form("sira")(i)
    veri.execute("update yazar set sira="&sira&"  where id="&id&"")
    next

    response.redirect "kose.asp"

      case "guncelle"
      id = request.form("id")
      rs.open "select * from yazi where id="&id,veri,1,3
      rs("baslik")=request.form("baslik")
      rs("yazi")=request.form("FCKeditor1")
      rs.update 
      %>
      <br><br>
		<table border="1" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#C0C0C0" width="100%" bgcolor="#F5F5F5">
<tr>
				<td width="100%">
				<p align="center"><font color="#CC3300"><br>
				Yazi Güncellendi 
				</font><br>
				<br>
				<a href="kose.asp">Köse yazilari yönetim ekranina dönmek için tiklayin</a><br>
				&nbsp;</td>
			</tr>
		</table>
      <%

       case "duzenle"
   id = request.querystring("id") 
      set yazi = veri.executE("select top 1 * from yazi where id="&id)
      if not yazi.eof then
      %>
      
      <script Language="JavaScript" Type="text/javascript"><!--
function kontrol(form)
{

  if (form.baslik.value == "")
  {
    alert("Yazynyza ba?lyk yazmadynyz.");
    form.baslik.focus();
    return (false);
  }
     return (true);    
}
//--></script>    
     	<br>
		<table border="0" cellpadding="4" style="border-collapse: collapse" bordercolor="#111111" width="100%">
			<form method="POST" action="?sayfa=guncelle" onsubmit="return kontrol(this)" language="JavaScript">
				<tr>
					<td width="100%" colspan="2"><b><font color="#CC3300">Yazi Düzenle</font></b></td>
				</tr>
				<tr>
					<td width="11%">Baslik</td>
					<td width="86%">
					<input type="text" name="baslik" size="49" value="<%=yazi("baslik")%>"></td>
				</tr><input type="hidden" name="id" value="<%=id%>">
		</table>
      <%
Dim sBasePath
sBasePath = Request.ServerVariables("PATH_INFO")
sBasePath = Left( sBasePath, InStrRev( sBasePath, "/" ) )

Dim oFCKeditor
Set oFCKeditor = New FCKeditor
oFCKeditor.BasePath	= sBasePath
oFCKeditor.Value	= yazi("yazi")
oFCKeditor.Create "FCKeditor1"
%>  <br>
<table border="0" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%">

					  <td width="22%">Yorum Yazilmasina Izin Ver </td>
					    <td width="178%">
					<input type="checkbox" name="yorum" value="ON" <%if yazi("yorum")=1 then response.write "checked" end if%>></td>
      </table><input type="submit" value="Güncelle">
     
     <%
     end if

       case "yazi_sil"
       id = request.querystring("id")
       veri.execute("delete from yazi where id="&id)
       veri.executE("delete from yorum where hid="&id)
       %><br><br>
		<table border="1" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#C0C0C0" width="100%" bgcolor="#F5F5F5">
<tr>
				<td width="100%">
				<p align="center"><font color="#CC3300"><br>
				Yazi Silindi<br>
				<br>
				<a href="kose.asp">Geri Dönmek Için Tiklayin</a></font><br>
				&nbsp;</td>
			</tr>
		</table>
       <%
       case "yazar_isle"
  	   i=1
	   rs.open "select * from yazar",veri,1,3
       rs.addnew
       rs("ad_soyad")=Request.form("ad_soyad")
       rs("mail")=Request.form("mail")
       rs("sifre")=Request.form("sifre")
       rs("sira")=Request.form("sira")
       rs("kulladi")=Request.form("kulladi")
       if Request.form("resim")<>"" then
	    rs("grafik1") = Request.form("resim")
	   else
	    rs("grafik1") = "resimyok.gif"
	  end if
	  rs.update
      response.redirect "kose.asp"
      case "yazar_ekle"%>
      <font color="#CC3300"> </font>
     <script Language="JavaScript" Type="text/javascript"><!--
function kontrol(form)
{

  if (form.ad_soyad.value == "")
  {
    alert("Yazarın adını yazmadınız.");
    form.ad_soyad.focus();
    return (false);
  }
       

      if (form.mail.value == "")
  {
    alert("Mail adresini yazmadınız.");
    form.mail.focus();
    return (false);
  }
     
      if (form.sifre.value == "")
  {
    alert("sifre yazmadınız.");
    form.sifre.focus();
    return (false);
  }
    if (form.kulladi.value == "")
  {
    alert("kullanici adi yazmadınız.");
    form.sifre.focus();
    return (false);
  }
  return (true);
}
//--></script> 
       	<table border="1" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#C0C0C0" width="100%">
		<form method="POST" action="?sayfa=yazar_isle" onSubmit="return kontrol(this)" language="JavaScript">
				<tr>
					<td colspan="3" bgcolor="#F5F5F5">
					<font color="#CC3300">Yazar Ekle</font></td>
		  </tr>
				<tr>
					<td width="216" style="border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium">Ad Soyad</td>
				  <td width="5" style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium">:</td>
				  <td width="337" style="border-left-style: none; border-left-width: medium; border-bottom-style: none; border-bottom-width: medium">
				  <input type="text" name="ad_soyad" size="25"></td>
		  </tr>
				<tr>
                  <td height="27" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">Mail</td>
                  <td style="border-style: none; border-width: medium">:</td>
                  <td style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">
                    <input type="text" name="mail" size="25"></td>
			  </tr>
				<tr>
                  <td style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">Kullanıcı Adı</td>
                  <td style="border-style: none; border-width: medium">:</td>
                  <td style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">
                    <p>
                      <input type="text" name="kulladi" size="20">
                  </p>                  </td>
			  </tr>
				<tr>
					<td width="216" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">Sifre</td>
				  <td width="5" style="border-style: none; border-width: medium">:</td>
				  <td width="337" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">
				  <input type="text" name="sifre" size="20"></td>
		  </tr>
				<tr>
					<td width="216" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style:none; border-bottom-width:medium">Yazarın Resmi</td>
				  <td width="5" style="border-style:none; border-width:medium; ">:</td>
				  <td width="337" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style:none; border-bottom-width:medium"><span style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium">
				    <input  name="resim" type="text" id="resim" size="25">
                    <a onClick="yenipencere('yazarresimyukle.asp',450,350)">Bilgisayardan Yükle</a></span></td>
		  </tr>
				<tr>
					<td width="216" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style:none; border-bottom-width:medium">Sira</td>
				  <td width="5" style="border-style:none; border-width:medium; ">:</td>
				  <td width="337" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style:none; border-bottom-width:medium">
				  <input type="text" name="sira" size="3" value="0"></td>
		  </tr>
				<tr>
					<td width="216" style="border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium">&nbsp;</td>
				  <td width="5" style="border-left-style: none; border-left-width: medium; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium">&nbsp;</td>
				  <td width="337" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium">
				  <input type="submit" value="Yazarı Ekle" name="B1"></td>
		  </tr>
			</form>
		</table>
      <% 
      case "yazar"
      yid = request.querystring("id")
      set yazar = veri.execute("select * from yazar where id="&yid)
      %>
      	<table border="0" cellpadding="4" style="border-collapse: collapse" bordercolor="#111111" width="100%">
			<tr>
				<td width="100%">Yazar : <b><%=yazar("ad_soyad")%></td>
			</tr>
        <%yazar.close : set yazar = nothing%>
      	</table><br><br>
      
<%
              rs.cachesize = 25 
              rs.pagesize  = 25
    rs.open "select baslik,id,tarih from yazi where yid = "&yid&" order by id desc",veri,1,3

if not rs.eof then
%>
		<table border="0" cellpadding="4" style="border-collapse: collapse" bordercolor="#111111" width="100%">
			<tr>
				<td width="62%"><font color="#CC3300">Baslik</font></td>
				<td width="23%"><font color="#CC3300">Tarih</font></td>
				<td width="8%">&nbsp;</td>
			</tr>
<%sayfa = Request.QueryString("sayfalar")
      If sayfa ="" Then sayfa="1"

      rs.absolutepage = sayfa

      sayfa_sayisi = rs.pagecount
      for i=1 to rs.pagesize
      If rs.eof Then exit for
	  if renk="" then
      renk=renk1 
      elseif renk=renk1 then
      renk=renk2
      elseif renk=renk2 then
      renk=renk1
      end if
      id = rs("id")
      %>

  			<tr bgcolor="<%=renk%>">
				<td width="62%"><%=rs("baslik")%></td>
				<td width="23%"><%=rs("tarih")%></td>
				<td width="8%"><a href="?sayfa=duzenle&id=<%=id%>">
				<img border="0" src="../admin/resim/kalem.gif"></a>&nbsp;
    			<a href="?sayfa=yazi_sil&id=<%=id%>">
				<img border="0" src="resim/sil.gif"></a></td>
			</tr>
  <%
    rs.movenext
    Next
  %>
 
		</table>
<script language="JavaScript">
function sayfasec(hangisi){
if (hangisi == 1) {
		document.kategori_sayfalari.submit();
	}
	else {
		document.kategori_sayfalari2.submit();
	}
}

                     </script>

		<br>
		<table border="0" cellpadding="3" style="border-collapse: collapse" bordercolor="#111111" width="100%">
			<tr>
				<td width="70%" bgcolor="#F5F5F5"><b><%=sayfa_sayisi%></b> Sayfada, Toplam<b> <%=rs.recordcount%></b> 
  Yazi</td>
				<form method="GET" action="kose.asp" name="kategori_sayfalari">
					<td width="30%" bgcolor="#F5F5F5" align="right">Sayfalar : 
					<select size="1" name="sayfalar" onChange="sayfasec(1);"><%
        
        for i=1 to sayfa_sayisi
        if i=int(sayfa) then
        sec=" selected"
        end if
        %>
				  <option value="<%=i%>"<%=sec%>><%=i%></option><%
        sec=""
        next
        %></select> </td>
				    <input type="hidden" name="sayfa" value="yazar">
                    <input type="hidden" name="id" value="<%=yid%>">
				</form>
			</tr>
		</table>
<%
else
response.write " <br><br> Henüz Bu Yazar Yazı Eklemedi."
end if
rs.close : set rs = nothing

  
      case "yazar_sil"
      id = request.querystring("id")
      veri.execute("delete from yazar where id="&id)
      veri.execute("delete from yazi where yid="&id)
      response.redirect "kose.asp"
      case "durum"
      veri.execute("update yazar set durum="&request.querystring("durum")&" where id="&request.querystring("id"))
      response.redirect "kose.asp"
      case else
       set yazar = veri.execute("select * from yazar order by sira asc")
       if not yazar.eof then
     %>
     	<table border="1" cellpadding="4" cellspacing="0" style="border-collapse: collapse" bordercolor="#C0C0C0" width="100%">
			<form method="POST" action="?sayfa=sg">
			<tr>
				<td width="17" bgcolor="#F5F5F5">&nbsp;</td>
				<td width="488" bgcolor="#F5F5F5"><font color="#CC3300">Yazar</font></td>
				<td width="88" bgcolor="#F5F5F5" align="center">
				<font color="#CC3300">Sira</font></td>
				<td width="121" bgcolor="#F5F5F5" align="center">
				<font color="#CC3300">Gelen Mesajlari</font></td>
				<td width="99" bgcolor="#F5F5F5" align="center">
				<font color="#CC3300">Yazi Sayisi</font></td>
				<td width="101" bgcolor="#F5F5F5"><div align="center"><font color="#CC3300">İşlemler</font></div></td>
			</tr>
       <%do while not yazar.eof
       id = yazar("id")
       %>
       		<tr>
				<td width="17"><%if yazar("durum")=1 then%>
            	<a hreF="?sayfa=durum&id=<%=id%>&durum=0">
				<img src="resim/pasif.gif" border="0"></a>
             <%else%>
             <a hreF="?sayfa=durum&id=<%=id%>&durum=1">
				<img src="resim/aktif.gif" border="0"></a>
<%end if%>
</td>
				<td width="488"><a href="?sayfa=yazar&id=<%=id%>"><%=yazar("ad_soyad")%></a>&nbsp;</td>
				<td width="88" align="center">
              <input type="text" name="sira" size="3" value="<%=yazar("sira")%>"></td><input type="hidden" name="id" value="F<%=id%>">
			  <td width="121" align="center"><%set saymesaj=veri.executE("select count(id) from yazarmesaj where yid="&id)
				response.write "<a href=""?sayfa=mesaj&yid="&id&""">"&saymesaj(0)&"</a>"
				saymesaj.close : set saymesaj = nothing%>&nbsp;</td>
			  <td width="99" align="center"><%set ysay=veri.execute("select count(id) from yazi where yid="&id)
         response.write ysay(0)
         ysay.close : set ysay = nothing%>&nbsp;</td>
				<td width="101"><div align="center"><a href="?sayfa=yazar_duzenle&id=<%=id%>">
			    <img border="0" src="resim/kalem.gif"></a>
				      <a href="?sayfa=yazar_sil&id=<%=id%>"  onclick="return confirm('Yazarı ve Yazarın Yazdığı Tüm Yazıları Silmek Üzeresiniz..!')">
	                <img border="0" src="resim/sil.gif"></a></div></td>
			</tr>    <%yazar.movenext : loop%>
       		<tr>
				<td colspan="5">
                <p align="right">
              <input type="submit" value="Güncelle" name="B1"></td>
			</tr>
            </form>
   
     	</table>
     <%
     else
     %>
     Henüz Yazar Eklemediniz.
    <%
     end if
       end select
       veri.close : set veri = nothing
    %></td>
	</tr>
</table>