弗尤博客(一)

 

参考博客园网站前端设计

由于html5不再支持frameset所以换成了iframe

相关介绍参考链接https://blog.youkuaiyun.com/sujin_/article/details/80144310

 

 

---恢复内容结束---

参考博客园网站前端设计

由于html5不再支持frameset所以换成了iframe

相关介绍参考链接https://blog.youkuaiyun.com/sujin_/article/details/80144310

 

  1 <%@ Master Language="C#" AutoEventWireup="true" CodeFile="Main.master.cs" Inherits="Main" %>
  2 
  3 <!DOCTYPE html>
  4 
  5 <html>
  6 <head runat="server">
  7 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
  8     <title></title>
  9     <asp:ContentPlaceHolder id="head" runat="server">
 10     </asp:ContentPlaceHolder>
 11     <style type="text/css">
 12         .auto-style1 {
 13             width: 100%;
 14         }
 15         .auto-style2 {
 16             width: 100%;
 17             height: 1000px;
 18         }
 19         .auto-style3 {
 20             /*width: 15%;*/
 21         }
 22         .auto-style4 {            width: 988px;
 23         }
 24         .auto-style5 {
 25             height: 1000px;
 26             width: 168px;
 27         }
 28         .auto-style6 {
 29             height: 1000px;
 30             width:750px;
 31         }
 32         .auto-style7 {
 33             height: 1000px;
 34             width: 266px;
 35         }
 36         .auto-style8 {
 37             width: 100%;
 38             height: 100px;
 39         }
 40         .auto-style9 {
 41             width: 168px;
 42         }
 43         </style>
 44 </head>
 45 <body>
 46     <form id="form1" runat="server">
 47     <div> 
 48         <table class="auto-style1">
 49                 <tr>
 50                     <td>代码改变世界</td>
 51                     <td style="text-align:right">
 52                         当前状态:<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
 53                         <asp:LinkButton ID="lb_blogs" runat="server" Font-Underline="False">我的博客</asp:LinkButton>
 54                         <asp:LinkButton ID="log" runat="server" Font-Overline="False">登录</asp:LinkButton>
 55                         <asp:LinkButton ID="lb_logoff" runat="server" Font-Underline="False">退出</asp:LinkButton>
 56                         <asp:LinkButton ID="lb_registe" runat="server" Font-Overline="False">注册</asp:LinkButton>
 57                     </td>
 58                 </tr>
 59                 <tr>
 60                     <td colspan="2" style="border-style: ridge; border-color: #00FFFF">
 61                         <asp:ImageButton ID="ImageButton1" runat="server" Height="100px" ImageUrl="~/image/logo.PNG" Width="200px" />
 62                     </td>
 63                 </tr>
 64             </table>
 65         <div style="background-color:steelblue">
 66             <asp:Menu ID="Menu1" runat="server" Font-Names="楷体" Font-Size="Large" ForeColor="White" Orientation="Horizontal">
 67                 <Items>
 68                     <asp:MenuItem Text="聊天室" Value="聊天室"></asp:MenuItem>
 69                     <asp:MenuItem Text="新闻" Value="新闻"></asp:MenuItem>
 70                     <asp:MenuItem Text="问一问" Value="问一问"></asp:MenuItem>
 71                     <asp:MenuItem Text="找找看" Value="找找看"></asp:MenuItem>
 72                 </Items>
 73             </asp:Menu>
 74         </div>
 75         <table cellspacing="6" class="auto-style2">
 76             <tr>
 77                 <td class="auto-style9">
 78                     <iframe class="auto-style5" src="MainLeft.aspx"></iframe>
 79                 </td>
 80                 <td class="auto-style4">
 81                     <iframe class="auto-style6" src="MainCenter.aspx"></iframe>
 82                 </td>
 83                 <td class="auto-style3">
 84                     <iframe class="auto-style7" src="MainRight.aspx"></iframe>
 85                 </td>
 86             </tr>
 87         </table>
 88         <div>
 89 
 90             <table class="auto-style8">
 91                 <tr>
 92                     <td style="text-align:center">
 93                         <asp:LinkButton ID="LinkButton1" runat="server">关于我们</asp:LinkButton>&nbsp;<asp:LinkButton ID="LinkButton2" runat="server">联系我们</asp:LinkButton>&nbsp;<asp:LinkButton ID="LinkButton3" runat="server">广告服务</asp:LinkButton>&nbsp;©2018-2019<asp:LinkButton ID="LinkButton4" runat="server">弗尤博客</asp:LinkButton></td>
 94                 </tr>
 95             </table>
 96 
 97         </div>
 98         <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">
 99         
100         </asp:ContentPlaceHolder>
101     </div>
102     </form>
103 </body>
104 </html>
View Code

准备通过母版页实现登陆,session记录状态,默认为游客状态,就可实现非登录情况下正常访问网站,首页顶部的linkbotton.text游客模式下只显示登录和注册,登录状态下显示我的博客和退出。不显示的都为空,网站会自动补充空白。

 

转载于:https://www.cnblogs.com/frankybpx/p/10077164.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值