[Dnsmail-cvs] projeler/ziyaretci-no FileNotFound.htm,NONE,1.1 GenericErrorPage.htm,NONE,1.1 NoAccess
Brought to you by:
ethem
From: Ayfer <ay...@us...> - 2006-05-26 23:28:50
|
Update of /cvsroot/dnsmail/projeler/ziyaretci-no In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv19980/ziyaretci-no Modified Files: Default.aspx Web.Config defter_data.mdb kayit.aspx kayit.aspx.cs Added Files: FileNotFound.htm GenericErrorPage.htm NoAccess.htm yonetim.aspx yonetim.aspx.cs Log Message: ziyaretçi defterinin yönetim sayfasý ve hata sayfalarýný ekledim. kayýt sayfasýna validation ekledim. genel olarak renkleri düzenledim. yönetim sayfasýnýn ad-þifre kýsmýný adýnýz:ayfer, þifre:123 yaptým. proje bende hatasýz çalýþýyor.Bir hata olursa söylerseniz sevinirim. --- NEW FILE: GenericErrorPage.htm --- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head> <title>Untitled Page</title> </head> <body bgcolor="#ffff99" > <span style="font-size: 32pt; color: #00fa9a; font-family: Forte">Genel hata Maalesef.. :(<br /> Anasayfaya Gitmek için </span><a href="Default.aspx"><span style="font-size: 32pt; font-family: Forte">Týklayýnýz.</span></a> </body> </html> --- NEW FILE: NoAccess.htm --- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head> <title>Untitled Page</title> </head> <body bgcolor="#ffccff"> <span style="font-size: 32pt; color: mediumspringgreen; font-family: Forte">Erisim Yok Maalesef.. :(<br /> Anasayfaya Gitmek için <a href="Default.aspx">Týklayýnýz.</a></span> </body> </html> Index: kayit.aspx.cs =================================================================== RCS file: /cvsroot/dnsmail/projeler/ziyaretci-no/kayit.aspx.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** kayit.aspx.cs 25 May 2006 23:54:19 -0000 1.1 --- kayit.aspx.cs 26 May 2006 23:28:43 -0000 1.2 *************** *** 15,25 **** protected void Button1_Click(object sender, EventArgs e) { ! ! OleDbConnection baglanti; OleDbCommand sorgu; - - - baglanti = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=/Yedek/Belgelerim/Visual Studio 2005/WebSites/WebSite5/defter_data.mdb"); baglanti.Open(); --- 15,21 ---- protected void Button1_Click(object sender, EventArgs e) { ! if (Page.IsValid){ OleDbConnection baglanti; OleDbCommand sorgu; baglanti = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=/Yedek/Belgelerim/Visual Studio 2005/WebSites/WebSite5/defter_data.mdb"); baglanti.Open(); *************** *** 33,38 **** OleDbDataReader veri; veri = sorgu.ExecuteReader(); - // datagrid.DataSource = veri; - // datagrid.DataBind(); baglanti.Close(); Panel1.Visible = false; --- 29,32 ---- *************** *** 40,43 **** --- 34,38 ---- HyperLink1.Visible = true; } + } } Index: Default.aspx =================================================================== RCS file: /cvsroot/dnsmail/projeler/ziyaretci-no/Default.aspx,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Default.aspx 25 May 2006 23:54:19 -0000 1.1 --- Default.aspx 26 May 2006 23:28:43 -0000 1.2 *************** *** 13,17 **** <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="kayit.aspx" Target="_self">Mesaj Yaz</asp:HyperLink> <asp:DataList ID="DataList1" runat="server" Caption="<b>Ziyaretci Mesajları</b>" CaptionAlign="Left" ! DataKeyField="ID" DataSourceID="AccessDataSource1" EnableTheming="True" BackColor="White" BorderColor="#E7E7FF" BorderStyle="None" BorderWidth="1px" CellPadding="3" GridLines="Horizontal" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" Width="1px"> <ItemTemplate> <table style="width: 300px; height: 100px" border=0> --- 13,17 ---- <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="kayit.aspx" Target="_self">Mesaj Yaz</asp:HyperLink> <asp:DataList ID="DataList1" runat="server" Caption="<b>Ziyaretci Mesajları</b>" CaptionAlign="Left" ! DataKeyField="ID" DataSourceID="AccessDataSource1" EnableTheming="True" BackColor="White" BorderColor="SeaGreen" BorderStyle="Solid" BorderWidth="1px" CellPadding="3" GridLines="Horizontal" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" Width="1px"> <ItemTemplate> <table style="width: 300px; height: 100px" border=0> *************** *** 44,53 **** <FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" /> <SelectedItemStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" /> ! <AlternatingItemStyle BackColor="#F7F7F7" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" /> ! <ItemStyle BackColor="MistyRose" ForeColor="#660099" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" HorizontalAlign="Left" /> ! <HeaderStyle BackColor="LightPink" Font-Bold="True" ForeColor="#F7F7F7" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" /> ! </asp:DataList> ! ! </div> </form> </body> --- 44,52 ---- <FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" /> <SelectedItemStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" /> ! <AlternatingItemStyle BackColor="PaleTurquoise" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" /> ! <ItemStyle BackColor="#FFC0FF" ForeColor="DarkGreen" Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" HorizontalAlign="Left" /> ! <HeaderStyle Font-Bold="True" ForeColor="#F7F7F7" Font-Italic="False" Font-Overline="False" Font-Strikeout="False" Font-Underline="False" /> ! </asp:DataList><br /> ! <asp:HyperLink ID="HyperLink2" runat="server" NavigateUrl="yonetim.aspx" Target="_self">Yönetim Sayfası</asp:HyperLink></div> </form> </body> Index: kayit.aspx =================================================================== RCS file: /cvsroot/dnsmail/projeler/ziyaretci-no/kayit.aspx,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** kayit.aspx 25 May 2006 23:54:19 -0000 1.1 --- kayit.aspx 26 May 2006 23:28:43 -0000 1.2 *************** *** 5,48 **** <html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server"> ! <title>Untitled Page</title> </head> <body> <form id="form1" runat="server"> <div> ! <asp:Panel ID="Panel1" runat="server" Height="282px" Width="421px"> ! <table border="0" style="width: 412px; height: 286px"> <tr> ! <td style="width: 96px; height: 10px;"> Ad soyad:</td> ! <td style="width: 13px; height: 10px;"> ! <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox></td> ! <td style="width: 23px; height: 10px;"> ! </td> </tr> <tr> ! <td style="width: 96px; height: 10px;"> Nereden:</td> ! <td style="width: 13px; height: 10px;"> <asp:TextBox ID="TextBox2" runat="server"></asp:TextBox></td> ! <td style="width: 23px; height: 10px;"> ! </td> </tr> <tr> ! <td style="width: 96px; height: 10px"> Meslek:</td> ! <td style="width: 13px; height: 10px"> <asp:TextBox ID="TextBox3" runat="server"></asp:TextBox></td> ! <td style="width: 23px; height: 10px"> ! </td> </tr> <tr> ! <td style="width: 96px; height: 36px"> Mesajınız:</td> ! <td style="width: 13px; height: 36px"> <asp:TextBox ID="TextBox4" runat="server" Height="177px" TextMode="MultiLine" Width="319px"></asp:TextBox></td> - <td style="width: 23px; height: 36px"> - </td> </tr> ! </table><asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Kaydet"></asp:Button></asp:Panel> </div> <asp:Label ID="Label1" runat="server" Text="Mesajınız Kaydedildi TeÅekkürler" Visible="False"></asp:Label><br /> --- 5,52 ---- <html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server"> ! <title>Ayfer _ Ziyaretci Defteri</title> </head> <body> <form id="form1" runat="server"> <div> ! <asp:Panel ID="Panel1" runat="server" Height="282px" Width="543px"> ! <table border="1" style="width: 513px; height: 298px"> <tr> ! <td style="width: 128px; height: 1px;"> Ad soyad:</td> ! <td style="width: 42px; height: 1px;"> ! <asp:TextBox ID="TextBox1" runat="server" Width="150px"></asp:TextBox> ! </td> ! <td style="width: 130px; height: 1px;"> ! <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="TextBox1" ! ErrorMessage="RequiredFieldValidator" Width="133px">Bu alan boÅ olamaz!!</asp:RequiredFieldValidator></td> </tr> <tr> ! <td style="width: 128px; height: 1px;"> Nereden:</td> ! <td style="width: 42px; height: 1px;"> <asp:TextBox ID="TextBox2" runat="server"></asp:TextBox></td> ! <td style="width: 130px; height: 1px;"> ! <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="TextBox2" ! ErrorMessage="RequiredFieldValidator" Width="130px">Bu alan boÅ olamaz!!</asp:RequiredFieldValidator></td> </tr> <tr> ! <td style="width: 128px; height: 1px"> Meslek:</td> ! <td style="width: 42px; height: 1px"> <asp:TextBox ID="TextBox3" runat="server"></asp:TextBox></td> ! <td style="width: 130px; height: 1px"> ! <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="TextBox3" ! ErrorMessage="RequiredFieldValidator" Width="130px">Bu alan boÅ olamaz!!</asp:RequiredFieldValidator></td> </tr> <tr> ! <td style="width: 128px; height: 36px"> Mesajınız:</td> ! <td colspan="2" style="height: 36px"> <asp:TextBox ID="TextBox4" runat="server" Height="177px" TextMode="MultiLine" Width="319px"></asp:TextBox></td> </tr> ! </table><asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Kaydet"></asp:Button> ! <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="TextBox4" ! ErrorMessage="RequiredFieldValidator">Mesaj kısmını boÅ bırakamazsınız!</asp:RequiredFieldValidator></asp:Panel> </div> <asp:Label ID="Label1" runat="server" Text="Mesajınız Kaydedildi TeÅekkürler" Visible="False"></asp:Label><br /> --- NEW FILE: yonetim.aspx --- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="yonetim.aspx.cs" Inherits="yonetim" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server"> <title>Ayfer _ Ziyaretci Defteri</title> </head> <body> <form id="form1" runat="server"> <div> <asp:AccessDataSource ID="AccessDataSource1" runat="server" DataFile="~/defter_data.mdb" SelectCommand="SELECT * FROM [defter]" UpdateCommand="UPDATE defter SET Ad = @ad, Nereden = @nereden, Meslek = @meslek, Mesaj = @mesaj where (ID=@id)" DeleteCommand="DELETE FROM defter WHERE (ID = @ID)"> </asp:AccessDataSource> </div> <asp:Panel ID="Panel2" runat="server" Height="223px" Width="790px" Visible="False"> <asp:GridView ID="GridData" runat="server" AutoGenerateColumns="False" DataKeyNames="ID" DataSourceID="AccessDataSource1" AllowSorting="True" BackColor="White" BorderColor="SeaGreen" BorderStyle="Solid" BorderWidth="1px" CellPadding="3" Font-Names="Arial Narrow" Font-Strikeout="False" GridLines="Horizontal"> <Columns> <asp:BoundField DataField="ID" HeaderText="ID" InsertVisible="False" SortExpression="ID" ReadOnly="True" > <ItemStyle BackColor="Teal" Font-Bold="True" ForeColor="White" /> </asp:BoundField> <asp:BoundField DataField="Ad" HeaderText="Ad" SortExpression="Ad" /> <asp:BoundField DataField="Nereden" HeaderText="Nereden" SortExpression="Nereden" /> <asp:BoundField DataField="Meslek" HeaderText="Meslek" SortExpression="Meslek" /> <asp:BoundField DataField="Mesaj" HeaderText="Mesaj" SortExpression="Mesaj" /> <asp:CommandField ShowEditButton="True" ButtonType="Button" CancelText="Ýptal" EditText="Düzelt" UpdateText="Kaydet" DeleteText="Sil" ShowDeleteButton="True" /> </Columns> <FooterStyle BackColor="Purple" ForeColor="White" /> <RowStyle BackColor="PaleTurquoise" BorderWidth="2px" ForeColor="Navy" /> <EditRowStyle Font-Underline="True" /> <SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" /> <PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" /> <HeaderStyle BackColor="Teal" BorderColor="White" Font-Bold="True" Font-Names="CityBlueprint" ForeColor="#F7F7F7" /> <AlternatingRowStyle BackColor="#FFC0FF" BorderStyle="Solid" BorderWidth="5px" /> </asp:GridView> <asp:HyperLink ID="HyperLink2" runat="server" NavigateUrl="kayit.aspx" Target="_self">Yeni kayýt ekle</asp:HyperLink><br /> <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="Default.aspx" Target="_self">anasayfa</asp:HyperLink></asp:Panel> <asp:Panel ID="Panel1" runat="server" Height="78px" Width="260px"> <strong><span style="font-size: 14pt">Adýnýz___:</span></strong><asp:TextBox ID="TextBox1" runat="server"></asp:TextBox><br /> <strong><span style="font-size: 14pt">Þifre____:</span></strong><asp:TextBox ID="TextBox2" runat="server"></asp:TextBox><br /> <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Tamam" /> <asp:Label ID="Label1" runat="server" ForeColor="Red"></asp:Label></asp:Panel> </form> </body> </html> --- NEW FILE: FileNotFound.htm --- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head> <title>Untitled Page</title> </head> <body bgcolor=NavajoWhite style="font-size: 12pt"> <span style="font-size: 24pt; color: mediumspringgreen"><strong><span style="font-size: 32pt"> <span style="font-family: Forte">Sayfa Bulunamadý Maalesef...:(<br /> Anasayfaya Gitmek için </span><a href="Default.aspx"><span style="font-family: Forte"> Týklayýnýz.</span></a></span><br /> </strong></span><a href="Default.aspx"></a> </body> </html> Index: defter_data.mdb =================================================================== RCS file: /cvsroot/dnsmail/projeler/ziyaretci-no/defter_data.mdb,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 Binary files /tmp/cvsFtzhWR and /tmp/cvszQJP5m differ Index: Web.Config =================================================================== RCS file: /cvsroot/dnsmail/projeler/ziyaretci-no/Web.Config,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Web.Config 25 May 2006 23:54:19 -0000 1.1 --- Web.Config 26 May 2006 23:28:43 -0000 1.2 *************** *** 1,40 **** <?xml version="1.0"?> ! <!-- ! Note: As an alternative to hand editing this file you can use the ! web admin tool to configure settings for your application. Use ! the Website->Asp.Net Configuration option in Visual Studio. ! A full list of settings and comments can be found in ! machine.config.comments usually located in ! \Windows\Microsoft.Net\Framework\v2.x\Config ! --> <configuration> <appSettings/> <connectionStrings/> <system.web> ! <!-- ! Set compilation debug="true" to insert debugging ! symbols into the compiled page. Because this ! affects performance, set this value to true only ! during development. ! --> <compilation debug="true"/> - <!-- - The <authentication> section enables configuration - of the security authentication mode used by - ASP.NET to identify an incoming user. - --> - <authentication mode="Windows"/> - <!-- - The <customErrors> section enables configuration - of what to do if/when an unhandled error occurs - during the execution of a request. Specifically, - it enables developers to configure html error pages - to be displayed in place of a error stack trace. ! <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm"> <error statusCode="403" redirect="NoAccess.htm" /> <error statusCode="404" redirect="FileNotFound.htm" /> </customErrors> ! --> </system.web> </configuration> --- 1,18 ---- <?xml version="1.0"?> ! <configuration> <appSettings/> <connectionStrings/> <system.web> ! <compilation debug="true"/> ! <authentication mode="Windows"/> ! ! <customErrors mode="On" defaultRedirect="GenericErrorPage.htm"> <error statusCode="403" redirect="NoAccess.htm" /> <error statusCode="404" redirect="FileNotFound.htm" /> </customErrors> ! </system.web> </configuration> --- NEW FILE: yonetim.aspx.cs --- using System; using System.Data; using System.Configuration; using System.Collections; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Web.UI.HtmlControls; public partial class yonetim : System.Web.UI.Page { protected void Button1_Click(object sender, EventArgs e) { if (TextBox1.Text == "ayfer") { if (TextBox2.Text == "123") { Panel1.Visible = false; Panel2.Visible = true; } else { Label1.Text = "Þifre Yanlýþ"; } } else { Label1.Text = "Ad Yanlýþ"; } } } |