<% if Request.QueryString("sayfasil")<>"" and Request.QueryString("sayfasil")<>10 and Request.QueryString("sayfasil")<>11 and Request.QueryString("sayfasil")<>49 then 
	sorgum="delete * from sayfa where id="&Request.QueryString("sayfasil")
	Rs.Open Sorgum, Baglantim, 1, 3
end if  %>
<style type="text/css">
<!--
.stil2 {font-family: Verdana, Arial, Helvetica, sans-serif; font-weight: bold; font-size: 11px; }
-->
</style>

<table width="100%" border="0">
  <tr>
    <td>
	
 <% sorgum="Select * from Sayfa where id<>10 or id<>11 or id<>49"
	Rs.Open Sorgum, Baglantim, 1, 3 %> 
	
	<% if Request.Form("ekle")<>"" then
		rs.addnew
		rs("goster")=false
		rs.update
		rs.close
		Response.Redirect("giris.asp")
	end if %>
	
	<% if Request.Form("Guncelle")<>"" then
	do while not rs.eof
		if Request.form("Sayfa_adi_"&rs("id"))<>"" then
			rs("adi")=Request.form("Sayfa_adi_"&rs("id"))
				if Request.form("Sayfa_goster_"&rs("id"))<>"True" then
					rs("goster")="false"
				else
					rs("goster")=true
				end if
			
			rs.update
		end if
	rs.movenext
	loop
	rs.close
	Response.Redirect("giris.asp")
	end if %>
	
	
	<form name="form1" method="post" action="">
      <table width="55%" align="center">
 	    <tr>
	      <td><div align="center" class="stil2">Aktif/Pasif</div></td>
	      <td><span class="stil2">Sayfa Adi</span></td>
	      <td colspan="2" align="center"><span class="stil2">Islemler</span></td>
	    </tr>     
       <% do while not rs.eof %>
	    <tr  <%if rs("id")=cint(Request.QueryString("id")) then %> class="mbon" <% end if %>>
          <td width="119" valign="bottom">
		    <div align="center">
		      <input name="Sayfa_goster_<%= rs("id") %>" type="checkbox" class="footersmin" id="Sayfa_goster_<%= rs("id") %>" value="True" <% if rs("goster")=true then %> checked <% end if %>>
	        </div></td>
          <td width="420" valign="bottom"><input name="Sayfa_adi_<%= rs("id") %>"skodu")_adi" type="text" class="footersmin" id="Sayfa_adi_<%= rs("id") %>" value="<%= rs("adi") %>" size="70" /></td>
          <td width="50" valign="bottom"><div align="center"><a href="?tablo=sayfa&id=<%= rs("id") %>"><img src="images/detay.jpg" border="0"/></a></div></td>
	      <td width="65" valign="bottom"><div align="center"><a href="?sayfasil=<%= rs("id") %>"><img src="images/sil.jpg" border="0"/></a></div></td>
	    </tr>
     <%  rs.movenext
	   loop %>
	    
	    <tr>
          <td colspan="4">            
            
              <div align="center">
                <input name="Ekle" type="submit" class="mbon" id="Ekle" value="Yeni Sayfa Ekle">
                &nbsp;&nbsp;
                <input name="Guncelle" type="submit" class="mbon" id="Guncelle" value="Sayfa Bilgilerini G&uuml;ncelle">
                </div></td>
          </tr>
      </table>
    </form>	</td>
  </tr>
</table>
<table width="100%" border="0" align="center">
<tr>
      <td valign="top" align="center">
        <% tablo=Request.QueryString("tablo")
	id=Request.QueryString("id") %>	
        <% if tablo<>"" and id<>"" then  %>
        <iframe src="../Editor/code/editor.asp?Tablo=<%= tablo %>&id=<%= id %>" width="800" height="500" frameborder="0" ></iframe>
	  <% end if %>	</td>
    </tr>
</table>
